Skip to content

Commit 9da4eb1

Browse files
committed
Bugfix to gzfile()
1 parent 0fe21a0 commit 9da4eb1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

singlecell/resources/chunks/Functions.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ saveData <- function(seuratObj, datasetId) {
107107
# Write cell barcodes and metadata:
108108
metaDf <- seuratObj@meta.data
109109
metaDf$cellbarcode <- colnames(seuratObj)
110-
conn <- gzfile(metaFile)
110+
conn <- gzfile(metaFile, 'w')
111111
write.table(metaDf, file = conn, quote = T, row.names = F, sep = ',', col.names = T)
112112
close(conn)
113113
write.table(data.frame(CellBarcode = colnames(seuratObj)), file = barcodeFile, quote = F, row.names = F, sep = ',', col.names = F)

0 commit comments

Comments
 (0)