Error in Read10X(data.dir
1
0
Entering edit mode
5 months ago

Hi, I am new to R and recently want to replicate a R demo with Seurat. The dataset is downloaded into my PC hard driver with the file name of "pbmc3k_filtered_gene_bc_matrices.tar.gz". I successfully loaded packages of dplyr, Seurat, patchwork which are required to run the code. Then, I tried to load dataset using code: pbmc.data<-Read10X(data.dir="~/R/10x/pbmc3k_filtered_gene_bc_matrices.tar.gz/") and get message "Error in Read10X(data.dir = "~/R/10x/pbmc3k_filtered_gene_bc_matrices.tar.gz/") : Directory provided does not exist. I have changed directory path and get the same error message. Please help. Thanks so much.

Seurat • 1.5k views
ADD COMMENT
2
Entering edit mode
5 months ago
antonioggsousa ★ 2.5k

Hi,

The files that you downloaded are tar.gz compressed (this can be decompressed in the command-line or using GUI programs - some OS like ubuntu can decompress it without any problem). Please decompress the files first and only then provide the path to the folder filtered_gene_bc_matrices/hg19/ like the tutorial mentions:

pbmc.data <- Read10X(data.dir = "../data/pbmc3k/filtered_gene_bc_matrices/hg19/")

Right now you're saying to import the files under the compressed folder:

"~/R/10x/pbmc3k_filtered_gene_bc_matrices.tar.gz/"

Which of course do not exist (Directory provided does not exist) because the software can not read anything under the compressed folder.

I hope this helps,

António

ADD COMMENT
0
Entering edit mode

You are absolutely right. Thanks so much.

ADD REPLY
0
Entering edit mode

I also have the same problem. I have tried to load the dataset using code: data <- Read10X(data.dir = "GSE162454_RAW"). I received an message error Directory provided does not exist Do you know where I've gone wrong? In the folder is 3 files: features, matrix and barcodes.

Thankyou

ADD REPLY
0
Entering edit mode

Perhaps you are not giving the full path to the folder. I'm not sure, but your problem seems to be different since your GSE162454_RAW folder is decompressed. Type the command in R list.files("GSE162454_RAW") to see if you can list the files from the directory where you are trying to import this. If you can list, I cannot figure out the problem. If you can't, it means that the path that you're giving is wrong.

António

ADD REPLY

Login before adding your answer.

Traffic: 1473 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6