Skip to content

Commit

Permalink
Re-enable metaphlan
Browse files Browse the repository at this point in the history
  • Loading branch information
kahsieh committed Nov 28, 2018
1 parent 3dd8944 commit 2e08815
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 18 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ of the pipeline. The following options are available:
- A comma-separated list of one or more of the following: lowq, rdna,
reference, repeats, circrna, immune, microbiome (which may be subdivided
into metaphlan, bacteria, viral, fungi, protozoa).
- circrna, metaphlan, and bacteria are not available in the current release.
- circrna and bacteria are not available in the current release.
- `-s all` selects everything.
- `-a|--fasta`: Input unmapped reads in .fasta format instead of .fastq format.
Forcibly disables low-quality read filtering.
Expand Down
19 changes: 6 additions & 13 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -182,27 +182,20 @@ else
cd ..

# Download MetaPhlAn 2.
#echo '----- Downloading MetaPhlAn 2 --------------------------------------------------'
#hg clone https://bitbucket.org/biobakery/metaphlan2
#cd metaphlan2
echo '----- Downloading MetaPhlAn 2 --------------------------------------------------'
hg clone https://bitbucket.org/biobakery/metaphlan2
cd metaphlan2
#ln -s ../../db_human/databases
#cd ..
cd ..

# Download MiniConda and add shebangs.
# Download MiniConda.
echo '----- Setting up Python environment --------------------------------------------'
if [ $NATIVE = false ]; then
./install-MiniConda.sh
cd MiniConda/lib
ln -s libncursesw.so.5 libtinfow.so.5
cd ../..
MiniConda="$PWD/MiniConda/bin/python"
# sed -i "1c #!$MiniConda" metaphlan2/metaphlan2.py
# sed -i "1c #!$MiniConda" metaphlan2/strainphlan.py
# sed -i "1c #!$MiniConda" metaphlan2/utils/read_fastx.py
#else
# sed -i '1c #!/usr/bin/env python2.7' metaphlan2/metaphlan2.py
# sed -i '1c #!/usr/bin/env python2.7' metaphlan2/strainphlan.py
# sed -i '1c #!/usr/bin/env python2.7' metaphlan2/utils/read_fastx.py
fi
fi

Expand Down Expand Up @@ -260,7 +253,7 @@ for database in $SELECT_DB; do
download_list+=$'\nmetaphlan\nviral\nviral_vipr\nfungi\nprotozoa'
;;
metaphlan)
#download_list+=$'\nmetaphlan'
download_list+=$'\nmetaphlan'
;;
viral)
download_list+=$'\nviral\nviral_vipr'
Expand Down
8 changes: 4 additions & 4 deletions rop.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ eval set -- "$PARSED"

# Set default options.
ORGANISM='human'
STEPS='rdna reference repeats viral fungi protozoa'
STEPS='rdna reference repeats immune metaphlan viral fungi protozoa'
# Non-default: lowq
# Disabled: circrna immune metaphlan bacteria
# Disabled: circrna bacteria
FASTA=false
BAM=false
GZIP=false
Expand Down Expand Up @@ -553,8 +553,8 @@ echo '7a. MetaPhlAn profiling (-s metaphlan)...'
cd "${DIRS['07a_metaphlan']}"
# No post file (don't reduce unmapped reads using MetaPhlAn results).

if ! grep -qE 'metaphlan|microbiome' <<<"$STEPS" || ! reads_present "$current" \
|| ! grep -q 'override' <<<"$STEPS"; then # Disabled (broken).
if ! grep -qE 'metaphlan|microbiome' <<<"$STEPS" || ! reads_present "$current";
then
echo '--> Skipped MetaPhlAn profiling.'
else
python "$DIR/tools/metaphlan2/metaphlan2.py" "$current" \
Expand Down

0 comments on commit 2e08815

Please sign in to comment.