<commit_before><tool id="qiime_filter_otus_from_otu_table" name="Filter otus from otu table" version="@WRAPPER_VERSION@.0">

    <description>Filter OTUs from an OTU table based on their observation counts or identifier</description>

    <macros>
        <import>macros.xml</import>
    </macros>

    <expand macro="requirements"/>

    <version_command>filter_otus_from_otu_table.py --version</version_command>

    <command detect_errors="aggressive"><![CDATA[
        filter_otus_from_otu_table.py
            -i '$input_fp'
            -o '$output_fp'
            #if $negate_ids_to_exclude:
                --negate_ids_to_exclude
            #end if
            #if $min_count:
                -n '$min_count'
            #end if
            #if $min_count_fraction:
                --min_count_fraction='$min_count_fraction'
            #end if
            #if $max_count:
                -x '$max_count'
            #end if
            #if $min_samples:
                -s '$min_samples'
            #end if
            #if $max_samples:
                -y '$max_samples'
            #end if
            #if str($otu_ids_to_exclude_fp) != 'None':
                -e '$otu_ids_to_exclude_fp'
            #end if
    ]]></command>

    <inputs>
        <param label="-i/--input_fp: the input otu table filepath in biom format" name="input_fp" optional="False" type="data"/>
        <param label="--negate_ids_to_exclude: keep OTUs in otu_ids_to_exclude_fp rather than discard them [default:False] " name="negate_ids_to_exclude" selected="False" type="boolean"/>
        <param default="0" label="-n/--min_count: the minimum total observation count of an otu for that otu to be retained [default: 0]" name="min_count" optional="True" type="integer"/>
        <param default="0" label="--min_count_fraction: fraction of the total observation (sequence) count to apply as the minimum total observation count of an otu for that otu to be retained. this is a fraction, not percent, so if you want to filter to 1%, you specify 0.01. [default: 0]" name="min_count_fraction" optional="True" type="float"/>
        <param default="inf" label="-x/--max_count: the maximum total observation count of an otu for that otu to be retained [default: infinity]" name="max_count" optional="True" type="integer"/>
        <param default="0" label="-s/--min_samples: the minimum number of samples an OTU must be observed in for that otu to be retained [default: 0]" name="min_samples" optional="True" type="integer"/>
        <param default="inf" label="-y/--max_samples: the maximum number of samples an OTU must be observed in for that otu to be retained [default: infinity]" name="max_samples" optional="True" type="integer"/>
        <param default="None" label="-e/--otu_ids_to_exclude_fp: file containing list of OTU ids to exclude: can be a text file with one id per line, a text file where id is the first value in a tab-separated line, or can be a fasta file (extension must be .fna or .fasta) [default: None]" name="otu_ids_to_exclude_fp" optional="True" type="data"/>
    </inputs>

    <outputs>
        <data format="txt" name="output_fp" label="${tool.name} on ${on_string}: Filter_otus_from_otu_table"/>
    </outputs>
<commit_msg>Filter_otus wrapper - Input and Output parameters update<commit_after><tool id="qiime_filter_otus_from_otu_table" name="Filter otus from otu table" version="@WRAPPER_VERSION@.0">

    <description>Filter OTUs from an OTU table based on their observation counts or identifier</description>

    <macros>
        <import>macros.xml</import>
    </macros>

    <expand macro="requirements"/>

    <version_command>filter_otus_from_otu_table.py --version</version_command>

    <command detect_errors="aggressive"><![CDATA[
        filter_otus_from_otu_table.py
            -i '$input_fp'
            -o '$output_fp'
            #if $negate_ids_to_exclude:
                --negate_ids_to_exclude
            #end if
            #if $min_count:
                -n '$min_count'
            #end if
            #if $min_count_fraction:
                --min_count_fraction='$min_count_fraction'
            #end if
            #if $max_count:
                -x '$max_count'
            #end if
            #if $min_samples:
                -s '$min_samples'
            #end if
            #if $max_samples:
                -y '$max_samples'
            #end if
            #if str($otu_ids_to_exclude_fp) != 'None':
                -e '$otu_ids_to_exclude_fp'
            #end if
    ]]></command>

    <inputs>
        <param argument="--input_fp" type="data" format="biom1" optional="False" label="Input OTU table" help="The input otu table filepath in biom format"  />
        <param argument="--min_count" type="integer" value="0" optional="True" label="Minimum total observation count of an otu for that otu to be retained" />
        <param argument="--min_count_fraction" type="float" value="0.0" optional="True" label="Fraction of the total observation (sequence) count to apply as the minimum total observation count of an otu for that otu to be retained" help="This is a fraction (float), not a percentage, so if you want to filter to 1%, you need to use 0.01 as value here" />
        <param argument="--max_count" type="integer" value="" optional="True" label="Maximum total observation count of an otu for that otu to be retained" />
        <param argument="--min_samples" type="integer" value="0" optional="True" label="Minimum number of samples an OTU must be observed in for that otu to be retained" />
        <param argument="--max_samples" type="integer" value="" optional="True" label="Maximum number of samples an OTU must be observed in for that otu to be retained" />

        <conditional name="id_filtering_condition">
            <param name="id_filtering_switch" type="select" label="Do you want to exclude a predefined list of OTUs from the OTU table ?" >
                <option value="no" selected="true">No</option>
                <option value="yes">Yes</option>
            </param>
            <when value="no"/>
            <when value="yes">
                <param argument="--otu_ids_to_exclude_fp" type="data" format="fasta,txt" optional="False"  label="Filtering by ID / Chimera filtering - Input text/Fasta file containing a list of OTU ids to exclude" help="The selected file can be a text file with one id per line, a text file where id is the first value in a tab-separated line, or can be a fasta file (extension must be .fna or .fasta)" />
                <param argument="--negate_ids_to_exclude" type="boolean" label="Do you want to reverse the filtering by ID / Chimera filtering ?" truevalue="--negate_ids_to_exclude" falsevalue="" checked="False" help="When this parameter is set to yes, then only the OTUs listed in the file passed to the --otu_ids_to_exclude_fp parameters will be kept in the output biom file" />
            </when>
        </conditional>
    </inputs>

    <outputs>
        <data name="output_fp" format="biom1" label="${tool.name} on ${on_string}: Filtered OTU table (biom format)"/>
    </outputs>

{'fraction_non_alphanumeric': 0.11261261261261261, 'fraction_numerical': 0.003096846846846847, 'mean_word_length': 2.817839871037077, 'pattern_counts': {'":': 0, '<': 66, '<?xml version=': 0, '>': 66, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '672611', 'n_tokens_mistral': 2149, 'n_tokens_neox': 2025, 'n_words': 689}