view modify_loom.xml @ 0:c8e4d0b9ae8c draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/anndata/ commit dc9d19d1f902f3ed54009cd0e68c8518c284b856"
author iuc
date Mon, 06 Jan 2020 13:43:38 -0500
parents
children 05631436cdf1
line wrap: on
line source

<tool id="modify_loom" name="Manipulate loom object" version="@VERSION@+@GALAXY_VERSION@">
    <description>Add layers, or row/column attributes to a loom file</description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="requirements"/>
    <expand macro="version_command"/>
    <command detect_errors="exit_code"><![CDATA[
python '$__tool_directory__/modify_loom.py' -f '${input}'
#if $which_add.add_type == "cols":
    -a cols -c '${which_add.cols}'
#else if $which_add.add_type == "cols":
    -a rows -r '${which_add.rows}'
#else if $which_add.add_type == "layers":
    -a layers -l '${which_add.layers}'
#end if
&& cp '${input}' loom_add_out.loom
      ]]></command>
    <inputs>
        <param name="input" type="data" format="loom" label="Loom file"/>
        <conditional name="which_add">
            <param name="add_type" type="select" label="Select data attribute to add to loom">
                <option value="cols">Columns</option>
                <option value="rows">Rows</option>
                <option value="layers">Layers</option>
            </param>
            <when value="cols">
                <param name="cols" type="data" format="tabular" label="Column file of same dimensions as existing file"/>
            </when>
            <when value="rows">
                <param name="rows" type="data" format="tabular" label="Row file of same dimensions as existing file"/>
            </when>
            <when value="layers">
                <param name="layers" type="data" multiple="true" format="tabular" label="Layer file(s) of same dimensions as existing file"/>
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data name="loomout" format="loom" from_work_dir='loom_add_out.loom' label="Expanded loom file from '${on_string}'"/>
    </outputs>
    <tests>
        <test expect_num_outputs="1">
            <param name="input" value="addtest.loom"/>
            <param name="add_type" value="cols"/>
            <param name="cols" value="cols.tsv"/>
            <output name="loomout" value="addloomout1.loom" ftype="loom" compare="sim_size"/>
        </test>
        <test expect_num_outputs="1">
            <param name="input" value="addtest.loom"/>
            <param name="add_type" value="rows"/>
            <param name="rows" value="rows.tsv"/>
            <output name="loomout" value="addloomout2.loom" ftype="loom" compare="sim_size"/>
        </test>
        <test expect_num_outputs="1">
            <param name="input" value="addtest.loom"/>
            <param name="add_type" value="layers"/>
            <param name="layers" value="addlayer1.tsv"/>
            <output name="loomout" value="addloomout3.loom" ftype="loom" compare="sim_size"/>
        </test>
    </tests>
    <help><![CDATA[
This tool allows the user to modify an existing loom data file by adding column attributes, row attributes or additional layers via tsv files.
    ]]></help>
    <citations>
        <citation type="bibtex">@UNPUBLISHED{Linnarsson2016,
            author = "Linnarsson lab"
            title = "Loompy"
            year = "2013"
            note = "https://github.com/linnarsson-lab/loompy"}
        </citation>
    </citations>
</tool>