view heinz_scoring.xml @ 2:704c401e0afb draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/heinz commit 392f981f8dd08fb4b98526cba17074736ff15b38"
author iuc
date Thu, 23 Jan 2020 14:07:54 -0500
parents e41ec5af7472
children
line wrap: on
line source

<tool id="heinz_scoring" name="Calculate a Heinz score" version="1.0">
    <description>for each node</description>
    <requirements>
        <requirement type="package" version="0.19.2">pandas</requirement>
        <requirement type="package" version="1.12.0">numpy</requirement>
    </requirements>
    <command detect_errors="aggressive"><![CDATA[
python '$__tool_directory__/heinz_scoring.py' -n '$node' -f '$FDR' -o '$score'
#if str( $input_type.input_type_selector ) == "bum_type":
    -l '$input_type.lambda' -a '$input_type.alpha'
#else:
    -m '$input_type.input_bum'
#end if
    ]]></command>
    <inputs>
        <param type="data" name="node" format="txt" label="A node file with p-values"
        help="The file should contain two columns: the node identifier (e.g. gene) and the corresponding p-value" />
        <param type="float" name="FDR" value="0.5" min="0" max="1" label="FDR value"
        help="False Discovery Rate (FDR), e.g. 0.0001"/>
        <conditional name="input_type">
            <param name="input_type_selector" type="select" label="Choose your input type for BUM parameters">
                <option value="bum_output" selected="True">The output file of BUM model</option>
                <option value="bum_type">Manually type the parameters of BUM model.</option>
            </param>
            <when value="bum_type">
                <param type="float" name="lambda" value="0.5" min="0" max="1" label="lambda" />
                <param type="float" name="alpha" value="0.5" min="0" max="1" label="alpha" />
            </when>
            <when value="bum_output">
                <param type="data" name="input_bum" format="txt" label="Output file of BUM model as input:
                lambda on the first line and alpha, the second" />
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data name="score" format="txt" label="${tool.name} on ${on_string}: Heinz scores" />
    </outputs>
    <tests>
        <!--Ensure the manual input of BUM parameters work-->
        <test>
            <param name="node" value="genes_with_a_p_value.csv" />
            <param name="FDR" value="0.001" />
            <param name="input_type_selector" value="bum_type" />
            <param name="lambda" value="0.546" />
            <param name="alpha" value="0.453" />
            <output name="score" file="Heinz_score_using_manual_BUM_params.txt" />
        </test>
        <!--Ensure the use of BUM output file as input work-->
        <test>
            <param name="node" value="genes_with_a_p_value.csv" />
            <param name="FDR" value="0.001" />
            <param name="input_type_selector" value="bum_output" />
            <param name="input_bum" value="BUM_output.txt" />
            <output name="score" file="Heinz_score_using_BUM_output.txt" />
        </test>
    </tests>
    <help><![CDATA[
This tool is used to calculate a Heinz score for each node (e.g., a gene). This
score further serves as the input of the tool "Identify optimal scoring subnetwork".

The input "Node file with p-values" should be like this:

========= ===================
K10970    0.00278208628672861
--------- -------------------
K10780    0.0029566591795884
--------- -------------------
K01484    0.0157152504694443
--------- -------------------
K09055    0.0188894478579773
========= ===================


The first column is "node identifier" (e.g., a gene name); the second column, "p-value";
The columns are delimited by a tab; no headers are needed.

The section "Choose your input type for BUM parameters" requires two alternative types of input:

1."The output of the BUM model" (The tool "Fit a BUM model"): the first line of the file
is lambda; the second, alpha.

2."Manually type the parameters of BUM model": lambda and alpha.


    ]]></help>
    <citations>
        <citation type="doi">10.1093/bioinformatics/btn161</citation>
        <citation type="doi">10.1093/bioinformatics/btg148</citation>
    </citations>
</tool>