# Various PhyloPhlAn 3.0 Errors for Nucleotide MAGs and Genomes

**URL:** <https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154>\
**Category:** PhyloPhlAn\
**Created:** [February 18, 2022, 12:48am UTC](https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154 "2022-02-18T00:48:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![brandi\_f](https://avatars.discourse-cdn.com/v4/letter/b/858c86/32.png) [@brandi\_f](https://forum.biobakery.org/u/brandi_f)\
**Post date:** [February 18, 2022, 12:48am UTC](https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154/1 "2022-02-18T00:48:49Z")

</div>

I am trying to generate a phylogenetic tree using 20 MAGs and 153 genomes all located in a directory titled “all\_fna\_files” (all files have the .fna extension).

I have downloaded PhyloPhlAn version 3.0.60 (27 November 2020).

I am having an issue generating the tree. The amphora2 database was not being generated, so I performed the following.  
Downloaded these files into phylophlan\_databases:  
[http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan\_databases.txt](http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan_databases.txt)  
[http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/amphora2.tar](http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/amphora2.tar)  
[http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/amphora2.md5](http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/amphora2.md5)  
[http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan.tar](http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan.tar)  
[http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan.md5](http://cmprod1.cibio.unitn.it/databases/PhyloPhlAn/phylophlan.md5)

cd /Users/brandifeehan/Documents/KSU\_PhD/Lee\_Lab/KSU/Stages\_MAGs/MAGs/Archaea/PhyloPhlAn/phylophlan\_databases  
tar -xf amphora2.tar  
bzcat amphora2/\*.bz2 \> amphora2/amphora2.faa  
tar -xf phylophlan.tar  
bunzip2 -k phylophlan/phylophlan.faa.bz2  
diamond makedb --in amphora2/amphora2.faa --db amphora2/amphora2  
diamond makedb --in phylophlan/phylophlan.faa --db phylophlan/phylophlan

I then submitted the following command and received the following error. I am uncertain of how to proceed.

(phylophlan) brandifeehan@ip-10-150-7-20 PhyloPhlAn % phylophlan -i all\_fna\_files/   
-d amphora2   
–diversity low   
-f supermatrix\_nt.cfg   
-t n

Generating “db\_dna” indexed database “amphora2”

[e] Command ‘[’/Users/brandifeehan/anaconda3\_new/bin/makeblastdb’, ‘-parse\_seqids’, ‘-dbtype’, ‘nucl’, ‘-in’, ‘/Users/brandifeehan/anaconda3\_new/envs/phylophlan/lib/python3.9/site-packages/phylophlan/phylophlan\_databases/amphora2/amphora2.fna’, ‘-out’, ‘/Users/brandifeehan/anaconda3\_new/envs/phylophlan/lib/python3.9/site-packages/phylophlan/phylophlan\_databases/amphora2/amphora2’]’ returned non-zero exit status 1.

[e] cannot execute command  
command\_line: /Users/brandifeehan/anaconda3\_new/bin/makeblastdb -parse\_seqids -dbtype nucl -in /Users/brandifeehan/anaconda3\_new/envs/phylophlan/lib/python3.9/site-packages/phylophlan/phylophlan\_databases/amphora2/amphora2.fna -out /Users/brandifeehan/anaconda3\_new/envs/phylophlan/lib/python3.9/site-packages/phylophlan/phylophlan\_databases/amphora2/amphora2  
stdin: None  
stdout: None  
env: {‘TERM\_PROGRAM’: ‘iTerm.app’, ‘TERM’: ‘xterm-256color’, ‘SHELL’: ‘/bin/zsh’, ‘TMPDIR’: ‘/var/folders/gm/dckmrbwj3hj27cj2jwnh7q8w0000gn/T/’, ‘CONDA\_SHLVL’: ‘2’, ‘CONDA\_PROMPT\_MODIFIER’: '(phylophlan) ', ‘TERM\_PROGRAM\_VERSION’: ‘3.4.15’, ‘TERM\_SESSION\_ID’: ‘w0t4p0:0A549096-86FC-46EE-B034-8DDA632F4F06’, ‘USER’: ‘brandifeehan’, ‘COMMAND\_MODE’: ‘unix2003’, ‘CONDA\_EXE’: ‘/Users/brandifeehan/anaconda3\_new/bin/conda’, ‘SSH\_AUTH\_SOCK’: ‘/private/tmp/com.apple.launchd.9dDrBlCvL9/Listeners’, ‘\_\_CF\_USER\_TEXT\_ENCODING’: ‘0x1F5:0x0:0x0’, ‘_CE\_CONDA’: ‘’, ‘CONDA\_PREFIX\_1’: ‘/Users/brandifeehan/anaconda3\_new’, ‘PATH’: ‘/Users/brandifeehan/anaconda3\_new/envs/phylophlan/bin:/Users/brandifeehan/anaconda3\_new/condabin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin’, '_’: ‘/Users/brandifeehan/anaconda3\_new/envs/phylophlan/bin/phylophlan’, ‘CONDA\_PREFIX’: ‘/Users/brandifeehan/anaconda3\_new/envs/phylophlan’, ‘\_\_CFBundleIdentifier’: ‘com.googlecode.iterm2’, ‘PWD’: ‘/Users/brandifeehan/Documents/KSU\_PhD/Lee\_Lab/KSU/Stages\_MAGs/MAGs/Archaea/PhyloPhlAn’, ‘LANG’: ‘en\_US.UTF-8’, ‘ITERM\_PROFILE’: ‘Default’, ‘XPC\_FLAGS’: ‘0x0’, ‘\_CE\_M’: ‘’, ‘XPC\_SERVICE\_NAME’: ‘0’, ‘SHLVL’: ‘1’, ‘HOME’: ‘/Users/brandifeehan’, ‘COLORFGBG’: ‘7;0’, ‘LC\_TERMINAL\_VERSION’: ‘3.4.15’, ‘ITERM\_SESSION\_ID’: ‘w0t4p0:0A549096-86FC-46EE-B034-8DDA632F4F06’, ‘CONDA\_PYTHON\_EXE’: ‘/Users/brandifeehan/anaconda3\_new/bin/python’, ‘LOGNAME’: ‘brandifeehan’, ‘CONDA\_DEFAULT\_ENV’: ‘phylophlan’, ‘LC\_TERMINAL’: ‘iTerm2’, ‘DISPLAY’: ‘/private/tmp/com.apple.launchd.ymEHjEBnPw/org.xquartz:0’, ‘COLORTERM’: ‘truecolor’}

---

<div class="post-metadata">

**Author:** ![f.asnicar](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/f.asnicar/32/196_2.png) [@f.asnicar](https://forum.biobakery.org/u/f.asnicar)\
**Post date:** [February 22, 2022, 12:02pm UTC](https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154/2 "2022-02-22T12:02:12Z")

</div>

Hi, first of all, thanks for trying PhyloPhlAn.

The error you reported is due to the wrong configuration file specified in the PhyloPhlAn command: `-f supermatrix_nt.cfg`. The `supermatrix_nt.cfg` is designed to work with a database of genes (hence the `_nt` suffix), while both `phylophlan` and `amphora2` databases are proteins. I think that changing the configuration file to `supermatrix_aa.cfg` should fix it.

The manual database extraction you did:

> [@brandi\_f](#):
>
> cd /Users/brandifeehan/Documents/KSU\_PhD/Lee\_Lab/KSU/Stages\_MAGs/MAGs/Archaea/PhyloPhlAn/phylophlan\_databases  
> tar -xf amphora2.tar  
> bzcat amphora2/\*.bz2 \> amphora2/amphora2.faa  
> tar -xf phylophlan.tar  
> bunzip2 -k phylophlan/phylophlan.faa.bz2  
> diamond makedb --in amphora2/amphora2.faa --db amphora2/amphora2  
> diamond makedb --in phylophlan/phylophlan.faa --db phylophlan/phylophlan

Should actually be not needed, as PhyloPhlAn will take care of it. Are you sure PhyloPhlAn is looking g at the correct databases folder? You can provided the path `/Users/brandifeehan/Documents/KSU_PhD/Lee_Lab/KSU/Stages_MAGs/MAGs/Archaea/PhyloPhlAn/phylophlan_databases` with the `--databases_folder` param.

Many thanks,  
Francesco

---

<div class="post-metadata">

**Author:** ![brandi\_f](https://avatars.discourse-cdn.com/v4/letter/b/858c86/32.png) [@brandi\_f](https://forum.biobakery.org/u/brandi_f)\
**Post date:** [February 22, 2022, 9:31pm UTC](https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154/3 "2022-02-22T21:31:21Z")

</div>

Francesco,

Thanks for your help!

I was under the impression the database would be generated after sending the command, but this is the error I was receiving previously (and now as well). This is why I was trying to download the databases manually.

**Command**  
phylophlan -i all\_fna\_files/ -d amphora2 -f supermatrix\_aa.cfg -t n --diversity low

**Errors**  
[w] cannot create database “amphora2”, section “db\_dna” not present in configurations  
[e] both db\_dna and db\_aa are None!

Thanks!  
Brandi

---

<div class="post-metadata">

**Author:** ![f.asnicar](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/f.asnicar/32/196_2.png) [@f.asnicar](https://forum.biobakery.org/u/f.asnicar)\
**Post date:** [February 23, 2022, 8:26am UTC](https://forum.biobakery.org/t/various-phylophlan-3-0-errors-for-nucleotide-mags-and-genomes/3154/4 "2022-02-23T08:26:49Z")

</div>

Dear Brandi,

Sorry I forgot to say that also the `-t n` param you specify for PhyloPhlAn is not correct, again that is to skip the automatic detection of the database type, but you’re specifying the database to be of genes. So, you should instead specify `-t a`.

Re:

> [@brandi\_f](#):
>
> [e] both db\_dna and db\_aa are None!

Please check your configuration file and make sure that the `db_aa` section is present (that’s what you need for indexing a database of proteins like `phylophlan` and `amphora2`.  
Then you should make sure you have the `map_dna` section as well as your inputs are genomes and MAGs (and not proteomes, if I understood correctly, in which case you would need also the `map_aa` section).

Finally, if you generate the configuration file with the `--force_nucleotides` param, then make sure to specify it also in the PhyloPhlAn command.

Please, let me know if something is not clear or not working.

Thanks, Francesco
