Importing Mothur into Phyloseqs cons.taxonomy error
Hi Everyone, I really want to use phyloseq to analyze and visualize my mothur 16s data but I cannot get the taxonomy file to import. I am using this tutorial: https://github.com/AndresICM/16S_metabarcoding_phyloseq
sharedfile="/fwmay/fwmay_comp.opti_mcc.shared"
taxfile="/fwmay/fwmay_comp.opti_mcc.0.03.cons.taxonomy"
mothur_data <- import_mothur(mothur_shared_file = sharedfile, mothur_constaxonomy_file = taxfile)
and I get this error:
Error in scan(file = file, what = what, sep = sep, quote = quote, dec = dec, :
line 146 did not have 3 elements
I have checked and I see no errors in the cons.taxonomy file and I am at a loss. I am really struggling to get this to work for my analysis. Any help would be greatly appreciated
• 1,114 views
•
link
0 answers
No answers yet.
Log in to answer this question.
Hi,
Can you open your taxonomy file (
/fwmay/fwmay_comp.opti_mcc.0.03.cons.taxonomy) in Excel or similar and look around the line number 146 and see what differs from the above lines. If you want you can print the result of that here. The error suggests that in line number 146 the number of elements (columns) differs from the previous rows.Best,
António
jahlen.pinelo : It may be simple to use one of the solutions in https://stackoverflow.com/questions/191364/quick-unix-command-to-display-specific-lines-in-the-middle-of-a-file and print the specific line(s) out.