Adding ignore_missing_samples argument

Hello everyone,

I am new to QIIME2 and have been having a reasonably easy time getting into it thanks to the tutorials, but I have now come to a complication with my data that I have not been able to find any info on in the forum.

I have received fastq data from another group ~1700 files from which I only need ~ 950 based on a condition. I have a metadata file with only the samples I need, but could not find a way to filter the fastq files before working with them in QIIME2. Therefore, I imported and cleaned all samples and got all the way to alpha and beta diversity analysis using the “Moving pictures” tutorial. When I input the code:

qiime diversity core-metrics-phylogenetic
–i-phylogeny rooted-tree.qza
–i-table table.qza
–p-sampling-depth 3000
–m-metadata-file full_metadata.tsv
–output-dir core-metrics-results

I get an error that ‘There are samples not included in the mapping file. Override this error by using the ignore_missing_samples argument.’ Of course I knew there were samples missing because my metadata file only includes my samples of interest.

So my questions from this are:

  1. Can anyone direct me to a fairly straight forward way of selecting my fastq files by sample id before starting in QIIME2?

and/or

  1. How do I add the ignore_missing_samples argument?

Thanks!

I have a better suggestion: now that you have already processed all samples, there is a very straightforward way to drop those samples from your feature table using metadata-based filtering. I believe just passing the metadata file containing the desired samples should drop the missing samples:

qiime feature-table filter-samples \
  --i-table table.qza \
  --m-metadata-file sample-metadata.tsv \
  --o-filtered-table filtered-table.qza

And then proceed!

We do not have a way in QIIME 2 to drop unwanted fastqs — the assumption being that users just won’t import these to begin with.

I hope that helps!

2 Likes

Hi @kesimmons!

Unfortunately, that parameter is not exposed in q2-emperor. I have raised an issue here (we would love a contribution if you or anyone you know is interested in assisting!). Thanks! :t_rex:

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.