Hi @jbisanz,
At the very end of your qiime2R tutorial, I was directed to MicrobeR tutorial. I am still using the same set of data, hoping to make some bar plots as in your tutorial, while got stuck in the summarize.taxa step. I ran following commands:
summarized.taxa=Summarize.Taxa(pilot_table_group, pilot_taxonomy)
and got following error message:
Error in TAXONOMY[rownames(FEATURES), ] : incorrect number of dimensions
I thought this might be caused by the taxonomy column, which is not separated into "kingdom", "phylum"..."Species". So I ran the commands to separate the taxon column in taxonomy file following your way mentioned in your qiim2R tutorial, and it worked. The new taxonomy file was "taxtable". Then, I rerun the command using taxtable instead:
summarized.taxa=Summarize.Taxa(pilot_table_group, taxtable)
then I got another error message:
Error in gsum(FEATURES) : GForce sum can only be applied to columns, not .SD or similar. To sum all items in a list such as .SD, either add the prefix base::sum(.SD) or turn off GForce optimization using options(datatable.optimize=1). More likely, you may be looking for 'DT[,lapply(.SD,sum),by=,.SDcols=]'
6.
gsum(FEATURES)
5.
gforce(thisEnv, jsub, o__, f__, len__, irows)
4.
`[.data.table`(SUMMARIZED.TAXA[[level]], , lapply(.SD, sum), by = TaxaString)
3.
SUMMARIZED.TAXA[[level]][, lapply(.SD, sum), by = TaxaString]
2.
as.data.frame(SUMMARIZED.TAXA[[level]][, lapply(.SD, sum), by = TaxaString])
1.
Summarize.Taxa(pilot_table_group, taxtable)
could you please let me know what happened for this step and how this could be fixed? Thank you very much.