Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in file.exists(file) : object 'data2_table.qza' not found #11

Open
yezi0721 opened this issue Apr 5, 2022 · 8 comments
Open

Error in file.exists(file) : object 'data2_table.qza' not found #11

yezi0721 opened this issue Apr 5, 2022 · 8 comments

Comments

@yezi0721
Copy link

yezi0721 commented Apr 5, 2022

setwd("~/squencing_analyze/R_microeco_package")
qiime2meco(ASV_data = data2_table.qza, sample_data = sample-metadata.tvs, taxonomy_data = taxonomy.qza, phylo_tree = tree.qza)
Error in file.exists(file) : object 'data2_table.qza' not found.

I feel confused about how to transfer my QIIME2 data to microtable? Under my working directory, it shows the error above.

@ChiLiubio
Copy link
Owner

Is your feature table file named "data2_table.qza" and in your working directory?

@yezi0721
Copy link
Author

yezi0721 commented Apr 6, 2022 via email

@Geize
Copy link

Geize commented May 7, 2022

Hi @ChiLiubio and yezi0721,

Here it does not work. I have the same problem. I also tried to put the whole path as well, but without successful.

@ChiLiubio
Copy link
Owner

Hi @Geize ,
Could you provide more details about the error or problem? I am not sure what is the key point to the problem.

@Geize
Copy link

Geize commented May 8, 2022

Hi @ChiLiubio,

Please, take a look - for qiime2 - using your script...

setwd("~/Documents/APlot/")

abund_file_path <- system.file("extdata", "~/Documents/APlot/tableDada2.qza", package="file2meco")
sample_file_path <-.....

qiime2meco(ASV_data = abund_file_path)

Error in read_qza(ASV_data) :
Input artifact () not found. Please check path and/or use list.files() to see files in current working directory.

list.files()
[1] "sample-metadata.tsv" "tableDada2.qza" "Taxonomy.qza"

Apparently, it only partial works when I use the same names that you indicate in your tutorial.

All the files were renamed according to your examples. Then, it works.

Going ahead, I got other issues.

I understood that I have to use unroot tree. Am I right?

Also, how should it name the fasta file with representative sequences?

Take a look on this:
[1] "dada2_rep_set.qza" "dada2_table.qza" "dna-sequences.fasta" "sample-metadata.tsv"
"taxonomy.qza" "tree.qza"

test1 <- qiime2meco(ASV_data = abund_file_path, sample_data = sample_file_path, taxonomy_data = taxonomy_file_path, phylo_tree = tree_data, rep_fasta = rep_data, auto_tidy = TRUE)

Error in self$tidy_dataset() :
No same feature name found among otu_table, tax_table and phylo_tree! Please check feature names in those objects !

In your code you write

please download fasta from https://docs.qiime2.org/2022.2/data/tutorials/pd-mice/dada2_rep_set.qza

the file name is 'dada2_rep_set.qza'

rep_data <- "dada2_rep_set.qza"

Here, it is fasta file or qza. To honest, I tried with both and nothing works.

@ChiLiubio
Copy link
Owner

Hi,
Please try this:
qiime2meco(ASV_data = "~/Documents/APlot/tableDada2.qza")
The system.file function is used to find the example file inside the package, maybe not what you need.

@mvtejesvi
Copy link

Hi @ChiLiubio,

I am having a similar problem, I am not sure how to solve it. Could you please help? When I try to import, it says the path to the artifact is not found, even though it is in the same directory. I also tried with full path, with no success. What could be the problem?

library(microeco)
d1 <-qiime2meco("table.qza")
No sample_table provided, automatically use colnames in otu_table to create one ...
d1
microtable-class object:
sample_table have 85 rows and 2 columns
otu_table have 3069 rows and 85 columns
dataset <- qiime2meco(ASV_data = "table.qza", sample_data = "metadata.tsv", taxonomy_data = "taxonomy.qza")
Error in read_qza(feature_table) : Path to artifact (.qza) not provided.

@ChiLiubio
Copy link
Owner

Hi. Please see the help document with command ?qiime2meco to check the parameter. I guess you are using file2meco v0.5.0. If yes, please see the help document and the latest tutorial (https://chiliubio.github.io/microeco_tutorial/file2meco-package.html#qiime2) to adjust the input parameters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants