ANCOM running for 30+ hours

I am trying to run ANCOM on 100 samples. Below is the code with the following parameters.

qiime composition ancom
–i-table comp-FC-table.qza
–m-metadata-file FC-Meta-Data.txt
–m-metadata-column Treatment
–o-visualization ancom-Treatment.qzv

The process has been running for more than 30 hours without giving me an error and I am concerned that it is not working correctly. Using the same parameters, I used the “Moving Pictures” tutorial data and the process took ~4-5 minutes to complete. Any suggestions would be much appreciated.

Hi @Kevin.Thomas,

There is probably not anything wrong — ANCOM can take a long time to run, particularly if there are many samples and/or features.

The best way to speed things up is to remove low-abundance features (e.g., < 100 total observations? it depends on the sampling depth etc) and feature that are unique to samples (shared by < 5 samples? Depends on the total # of samples, size of groups, and goals of your analysis). These rare features will really slow things down.

That's a tiny test dataset (subsampled from a much larger one) — this subsample is used in the tutorial specifically to make commands fast and easy to run, but this does not give a good estimate of runtime for full data sets. It should give you an idea, though — if a tiny test dataset takes 5 min to run, a full-sized dataset will often take hours.

30 hr sounds like a record to me, but again it depends on the characteristics of the data. You might not be interested in those rare OTUs anyway, so I'd recommend killing the job, filtering your data, and re-running.

I hope that helps!

1 Like

This makes a lot of sense, filtering would be a good idea before attempting to run this. However, I’ve tried filtering my data using the command below.

qiime feature-table filter-features
–i-table FC-table.qza
–p-min-samples 25
–p-min-frequency 100
–o-filtered-table FC-sample-contingency-filtered-table.qza

Then, using the output table from filtering, when I attempt to collapse the table at the genus level using

qiime taxa collapse
–i-table FC-sample-contingency-filtered-table.qza
–i-taxonomy FC-taxonomy.qza
–p-level 2
–o-collapsed-table FC-table-collapsed-genus.qza

it gives me an error when plugging this output table into the ANCOM table parameter.

Plugin error from composition:

Argument to parameter ‘table’ is not a subtype of FeatureTable[Composition].

Any ideas on where to go from here? It seems like filtering the data is causing the issue.

You need to use add-psuedocount to convert your FeatureTable[Frequency] to FeatureTable[Composition]. Judging from the file names, it sounds like you did this on the original feature table and forgot to re-run that step on the filtered table.

Let us know if that helps!

This solved the issue! Thank you for the assistance and quick response times!

2 Likes

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