view artic_minion.xml @ 0:c411e2205442 draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/artic commit 41ad91410844b6d399844b253e39fa29955b96d6"
author iuc
date Thu, 30 Apr 2020 04:05:09 -0400
parents
children 20165d3a8fb1
line wrap: on
line source

<tool id="artic_minion" name="ARTIC minion" version="1.1.0_rc2+galaxy0">
    <description></description>
    <requirements>
        <requirement type="package" version="1.1.0_rc2">artic</requirement>
    </requirements>
    <command detect_errors="exit_code"><![CDATA[
        mkdir -p 'scheme/name/version' &&
        #if str( $primer_scheme_source.primer_scheme_source_selector ) == "tool_data_table":
          ln -s '${primer_scheme_source.primer_scheme_bedfile.fields.path}' 'scheme/name/version/name.scheme.bed' &&
        #else:
          ln -s '${primer_scheme_source.primer_scheme_bedfile}' 'scheme/name/version/name.scheme.bed' &&
        #end if
        #if str( $reference_source.reference_source_selector ) == "history":
          ln -s '${reference_source.reference}' 'scheme/name/version/name.reference.fasta' &&
          samtools faidx 'scheme/name/version/name.reference.fasta' &&
        #else:
          ln -s '${reference_source.reference.fields.path}' 'scheme/name/version/name.reference.fasta' &&
          samtools faidx 'scheme/name/version/name.reference.fasta' &&
        #end if
        artic minion
            --threads \${GALAXY_SLOTS:-1}
            --normalise '${normalise}'
            --read-file '${read_file}'
            --scheme-directory 'scheme'
            --medaka
            $bwa
            'name/version'
            '${read_file.element_identifier}'
    ]]></command>
    <inputs>
        <param argument="--read-file" type="data" format="fastq,fastqsanger,fastq.gz,fastqsanger.gz" label="Input Read File"/>
        <param argument="--normalise" type="integer" min="1" value="200" max="2000" label="Coverage normalisation depth"/>
        <param argument="--bwa" type="boolean" truevalue="--bwa" falsevalue="" label="Use bwa aligner"/>
        <conditional name="primer_scheme_source">
            <param name="primer_scheme_source_selector" type="select" label="Select a primer scheme from your history or use one from a tool data table?"
                   help="Screening files must be stored in the 'primer_scheme_bedfiles' tool data table">
                <option value="tool_data_table">From tool data table</option>
                <option value="history">From history</option>
            </param>
            <when value="tool_data_table">
                <param name="primer_scheme_bedfile" type="select" format="bed" label="Primer Scheme">
	            <options from_data_table="primer_scheme_bedfiles">
	                <validator type="no_options" message="No primer scheme .bed files are available" />
                    </options>
	        </param>
            </when>
            <when value="history">
                <param name="primer_scheme_bedfile" type="data" format="bed" label="Primer Scheme" />
            </when>
        </conditional>
        <conditional name="reference_source">
            <param name="reference_source_selector" type="select" label="Will you select a reference genome from your history or use a built-in reference?" >
                <option value="cached">Use a built-in reference</option>
                <option value="history">Use a reference from history</option>
            </param>
            <when value="cached">
                <param name="reference" type="select" label="Using reference genome" help="Select genome from the list">
                    <options from_data_table="all_fasta">
                        <filter type="sort_by" column="2" />
                        <validator type="no_options" message="No references are available" />
                    </options>
                </param>
            </when>
            <when value="history">
                <param name="reference" type="data" format="fasta" label="Use the following dataset as the reference sequence"
                       help="You can upload a FASTA sequence to the history and use it as reference" />
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data name="alignment_trimmed" format="bam" from_work_dir="*.trimmed.bam" label="${tool.name} on ${on_string}: trimmed alignment" />
        <data name="variants_tabular" format="tabular" from_work_dir="*.variants.tab" label="${tool.name} on ${on_string}: variants table" />
        <data name="variants_merged_vcf" format="vcf_bgzip" from_work_dir="*.merged.vcf.gz" label="${tool.name} on ${on_string}: variants vcf" />
        <data name="consensus_fasta" format="fasta" from_work_dir="*.consensus.fasta" label="${tool.name} on ${on_string}: consensus sequence" />
    </outputs>
    <tests>
        <test>
            <param name="reference_source_selector" value="history" />
            <param name="read_file" value="SRR11410539_seqtk_sample_250_1.fastq" />
            <param name="reference" value="nCoV-2019.reference.fasta" />
            <param name="primer_scheme_source_selector" value="tool_data_table" />
            <param name="primer_scheme_bedfile" value="test_entry" />
            <output name="consensus_fasta" file="SRR11410539_seqtk_sample_250_1.fastq.consensus.fasta" />
        </test>
        <test>
            <param name="reference_source_selector" value="history" />
            <param name="read_file" value="SRR11410539_seqtk_sample_250_1.fastq" />
            <param name="reference" value="nCoV-2019.reference.fasta" />
            <param name="primer_scheme_source_selector" value="history" />
            <param name="primer_scheme_bedfile" value="nCoV-2019.V1.bed" />
            <output name="consensus_fasta" file="SRR11410539_seqtk_sample_250_1.fastq.consensus.fasta" />
        </test>
        <test>
            <param name="reference_source_selector" value="tool_data_table" />
            <param name="read_file" value="SRR11410539_seqtk_sample_250_1.fastq" />
            <param name="reference" value="test_entry" />
            <param name="primer_scheme_source_selector" value="tool_data_table" />
            <param name="primer_scheme_bedfile" value="test_entry" />
            <output name="consensus_fasta" file="SRR11410539_seqtk_sample_250_1.fastq.consensus.fasta" />
        </test>
    </tests>
    <help><![CDATA[
This tool aligns MinION reads that were generated from a tiling amplicon library against a viral reference sequence. 
It generates a consensus fasta file and a vcf variant file.

This tool is configured to use the experimental 'medaka' variant caller.
    ]]></help>
    <citations>
    </citations>
</tool>