Repository revision
3:4212f20315e5

Repository 'customize_metaphlan_database'
hg clone https://toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database

Customize the marker sequences and metadata tool metadata
Miscellaneous
from the MetaPhlAn database
customize_metaphlan_database
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.13+galaxy0
3.0.13+galaxy0
metaphlan -v
True
Version lineage of this tool (guids ordered most recent to oldest)
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.14+galaxy0
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.13+galaxy0 (this tool)
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.9+galaxy0
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.8+galaxy0
toolshed.g2.bx.psu.edu/repos/iuc/customize_metaphlan_database/customize_metaphlan_database/3.0.7+galaxy0
customize_metaphlan_database
Requirements (dependencies defined in the <requirements> tag set)
name version type
metaphlan 3.0.13 package
seqtk 1.3 package
Additional information about this tool
python '$__tool_directory__/customizemetadata.py'
    $op.operation

#if $op.operation == "add_marker"
    --in_json '$in_json'
    --out_json '$out_json'
    --name $op.name
    --m_length $op.m_length
        #for $s in $op.genomes
    --g_length $s.g_length
            #if str($s.gca) != ''
    --gca '$s.gca'
            #else
    --gca ''
            #end if
    --k_name '$s.k_name'
    --k_id $s.k_id
    --p_name '$s.p_name'
    --p_id $s.p_id
    --c_name '$s.c_name'
    --c_id $s.c_id
    --o_name '$s.o_name'
    --o_id $s.o_id
    --f_name '$s.f_name'
    --f_id $s.f_id
    --g_name '$s.g_name'
    --g_id $s.g_id
    --s_name '$s.s_name'
    --s_id $s.s_id
    --t_name '$s.t_name'
        #end for
&&
cat 
    '$in_fasta'
    '$op.marker_seq'
    > '$out_fasta'

#else if $op.operation == "remove_markers"
    --in_json '$in_json'
    --markers '$op.markers'
    --out_json '$out_json'
    --kept_markers 'kept_makers'
&&
seqtk subseq
    '$in_fasta'
    'kept_makers'
    > '$out_fasta'

#else if $op.operation == "keep_markers"
    --in_json '$in_json'
    --markers '$op.markers'
    --out_json '$out_json'
&&
seqtk subseq
    '$in_fasta'
    '$op.markers'
    > '$out_fasta'
#end if
    
None
False
Functional tests
name inputs outputs required files
Test-1 in_fasta: test-db-without-one-marker.fasta
in_json: test-db-without-one-marker.json
op|marker_seq: marker_sequence.fasta
op|name: 13076__A0A2I1PE66__CYJ72_10760
op|m_length: 540
op|genomes_0|g_length: 2411251
op|genomes_0|gca: GCA_002847845
op|genomes_0|k_name: Bacteria
op|genomes_0|k_id: 2
op|genomes_0|p_name: Bacilli
op|genomes_0|p_id: 1239
op|genomes_0|c_name: Negativicutes
op|genomes_0|c_id: 91061
op|genomes_0|o_name: Lactobacillales
op|genomes_0|o_id: 186826
op|genomes_0|f_name: Aerococcaceae
op|genomes_0|f_id: 186827
op|genomes_0|g_name: Globicatella
op|genomes_0|g_id: 13075
op|genomes_0|s_name: Globicatella_sanguinis
op|genomes_0|s_id: 13076
op|genomes_0|t_name: GCA_002847845
op|operation: add_marker
name: value
name: value
test-db-without-one-marker.fasta
test-db-without-one-marker.json
marker_sequence.fasta
value
Test-2 in_fasta: test-db.fasta
in_json: test-db.json
op|markers: marker.txt
op|operation: remove_markers
name: value
name: value
test-db.fasta
test-db.json
marker.txt
value
Test-3 in_fasta: test-db.fasta
in_json: test-db.json
op|markers: marker.txt
op|operation: keep_markers
name: value
name: value
test-db.fasta
test-db.json
marker.txt
value