view seurat_filter_cells.xml @ 5:c4b984347138 draft

"planemo upload for repository https://github.com/ebi-gene-expression-group/container-galaxy-sc-tertiary/ commit 355bb52d2e9d170b1db237e649657cc14e0a047a"
author ebi-gxa
date Fri, 04 Mar 2022 07:25:34 +0000
parents ebf7286c8b97
children
line wrap: on
line source

<tool id="seurat_filter_cells" name="Seurat FilterCells" profile="18.01" version="@SEURAT_VERSION@+galaxy0">
    <description>filter cells in a Seurat object</description>
    <macros>
        <import>seurat_macros.xml</import>
    </macros>
    <expand macro="requirements" />
    <expand macro="version" />
    <command detect_errors="exit_code"><![CDATA[
seurat-filter-cells.R
@INPUT_OBJECT@
#if $subsets:
    #set subsets_clause = ','.join(['{name}'.format(**$s) for $s in $subsets])
    #set low_clause = ",".join(['{min}'.format(**$s) for $s in $subsets])
    #set high_clause = ",".join(['{max}'.format(**$s) for $s in $subsets])
    --subset-names '${subsets_clause}' --low-thresholds '${low_clause}' --high-thresholds '${high_clause}'
#end if

#if $cells:
    --cells-use $cells
#end if
@OUTPUT_OBJECT@
]]></command>

    <inputs>
        <expand macro="input_object_params"/>
        <repeat name="subsets" title="Subsets used to filter cells" min="1">
          <param name="name" argument="--subset-names" type="text" label="Name of parameter to filter on" help="for example nCount_RNA, nFeature_RNA, the name of a gene, PC1, a column name in object@meta.data, etc. Any argument that can be retreived using FetchData.">
            <validator type="regex" message="Please only use letters or numbers">^[\(\w\)]+$</validator>
            <option value="nCount_RNA">nCount_RNA</option>
            <option value="nFeature_RNA">nFeature_RNA</option>
          </param>
          <param name="min" type="float" value="0" min="0" label="Min value"/>
          <param name="max" type="float" value="1e9" label="Max value"/>
        </repeat>
        <param name="cells" argument="--cells-use" type="text" min="0" optional="True" help="Comma-separated list of cell names to use as a subset." label="Cells to use" />
        <expand macro="output_object_params"/>
    </inputs>

    <outputs>
        <expand macro="output_files"/>
    </outputs>

    <tests>
        <test>
            <param name="name" value="nCount_RNA" />
            <param name="rds_seurat_file" ftype="rdata" value="E-MTAB-6077-3k_features_90_cells.rds" />
            <output name="rds_seurat_file" ftype="rdata">
              <assert_contents>
                <has_size value="2260044" delta="200000"/>
              </assert_contents>
            </output>
        </test>
    </tests>
    <help><![CDATA[
.. class:: infomark

**What it does**

This tool filters cells in a Seurat object.

@SEURAT_INTRO@

-----

**Inputs**

    * Seurat RDS object. Probably the one produced by Seurat create object.
    * Subset names. A list of attributes to subset on, colon separated (:).
    * Low thresholds. A minimum value for each of the attributes set in subset names, again, colon separated (:). Optional.
    * High thresholds. A maximum value for each of the attributes set in subset names, again, colon separated (:). Optional.
    * Cells to use. A list of cell names/idenfifiers to filter positively by.

-----

**Outputs**

    * Seurat RDS object filtered according to the inputs.

.. _Seurat: https://www.nature.com/articles/nbt.4096
.. _Satija Lab: https://satijalab.org/seurat/

@VERSION_HISTORY@

]]></help>
      <expand macro="citations" />
</tool>