Mercurial > repos > iuc > fastk_fastk
comparison fastk.xml @ 0:794d07dc1c68 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/fastk commit 9257c0d48c94f40919d29e48f210c58099608aa7
| author | iuc |
|---|---|
| date | Mon, 04 Nov 2024 14:20:00 +0000 |
| parents | |
| children | b446c2f40b60 |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:794d07dc1c68 |
|---|---|
| 1 <tool id="fastk_fastk" name="FastK" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="23.2"> | |
| 2 <description>A k-mer counter for high-quality assembly datasets</description> | |
| 3 <macros> | |
| 4 <import>macros.xml</import> | |
| 5 </macros> | |
| 6 <expand macro="requirements" /> | |
| 7 <command detect_errors="exit_code"><![CDATA[ | |
| 8 mkdir -p outfiles/ktabfiles && | |
| 9 #if $infile.is_of_type("fastq"): | |
| 10 #set INPUTFILE="input.fastq" | |
| 11 #elif $infile.is_of_type("fastq.gz"): | |
| 12 #set INPUTFILE="input.fastq.gz" | |
| 13 #else | |
| 14 #set INPUTFILE="input."+$infile.ext | |
| 15 #end if | |
| 16 ln -s '$infile' $INPUTFILE && | |
| 17 FastK $INPUTFILE | |
| 18 -k$kmer_size | |
| 19 #if $sorted_table.sorted_table_option == 'yes_with_default': | |
| 20 -t | |
| 21 #elif $sorted_table.sorted_table_option == 'yes_with_custom': | |
| 22 -t$sorted_table_cutoff | |
| 23 #end if | |
| 24 -T\${GALAXY_SLOTS:-8} -Noutfiles/output -Poutfiles/ktabfiles | |
| 25 #if $sorted_table.sorted_table_option == 'yes_with_default': | |
| 26 && Tabex outfiles/output.ktab -t${sorted_table.tabex_threshold_for_default} LIST > '$tabex_hist' | |
| 27 && cp outfiles/.*.ktab* outfiles/ktabfiles | |
| 28 && cp outfiles/*.ktab outfiles/ktabfiles | |
| 29 #elif $sorted_table.sorted_table_option == 'yes_with_custom': | |
| 30 && Tabex outfiles/output.ktab -t${sorted_table.tabex_threshold_for_custom} LIST > '$tabex_hist' | |
| 31 && cp outfiles/.*.ktab* outfiles/ktabfiles | |
| 32 && cp outfiles/*.ktab outfiles/ktabfiles | |
| 33 #end if | |
| 34 && tar -c -f fastk.tar ./outfiles/ | |
| 35 ]]></command> | |
| 36 <inputs> | |
| 37 <param name="infile" type="data" format="fasta,fasta.gz,fastq,fastq.gz,cram,unsorted.bam,sam" label="Input file"/> | |
| 38 <param name="kmer_size" argument="-k" type="integer" min="5" max="50" value="40" label="Enter desired k-mer size" help="Default: 40"/> | |
| 39 <conditional name="sorted_table"> | |
| 40 <param name="sorted_table_option" type="select" label="Sort table" help="Do you want a sorted table of all canonical k-mers and their counts? The sorted table is sorted lexicographically on the k-mer where a < c < g < t."> | |
| 41 <option value="no">No</option> | |
| 42 <option value="yes_with_default">Yes, Default sorted </option> | |
| 43 <option value="yes_with_custom">Yes, Custom sorted </option> | |
| 44 </param> | |
| 45 <when value="no"/> | |
| 46 <when value="yes_with_default"> | |
| 47 <param name="tabex_threshold_for_default" argument="-t" type="integer" value="5" min="1" label="Tabex count threshold" help="Trim all k-mers with counts less than threshold"/> | |
| 48 </when> | |
| 49 <when value="yes_with_custom"> | |
| 50 <param name="sorted_table_cutoff" type="integer" min="2" value="10" label="Enter sorted table cutoff value"/> | |
| 51 <param name="tabex_threshold_for_custom" argument="-t" type="integer" value="5" min="1" label="Tabex count threshold" help="Trim all k-mers with counts less than threshold"/> | |
| 52 </when> | |
| 53 </conditional> | |
| 54 </inputs> | |
| 55 <outputs> | |
| 56 <data name="fastk_out" format="tar" from_work_dir="fastk.tar" label="${tool.name} on ${on_string}: FastK files"/> | |
| 57 <data name="fastk_hist_out" format="fastk_hist" from_work_dir="outfiles/output.hist" label="${tool.name} on ${on_string}: FastK hist"/> | |
| 58 <data name="fastk_ktab_out" format="fastk_ktab" from_work_dir="outfiles/ktabfiles/output.ktab" label="${tool.name} on ${on_string}: FastK ktab"> | |
| 59 <filter> sorted_table['sorted_table_option'] != 'no' </filter> | |
| 60 </data> | |
| 61 <data name="tabex_hist" format="txt" label="${tool.name} on ${on_string}: Tabex output"> | |
| 62 <filter> sorted_table['sorted_table_option'] != 'no' </filter> | |
| 63 </data> | |
| 64 </outputs> | |
| 65 <tests> | |
| 66 <!-- TEST 1 --> | |
| 67 <test expect_num_outputs="2"> | |
| 68 <param name="infile" value="input01.fasta.gz"/> | |
| 69 <output name="fastk_out" ftype="tar"> | |
| 70 <assert_contents> | |
| 71 <has_archive_member path="./outfiles/output.hist"/> | |
| 72 </assert_contents> | |
| 73 </output> | |
| 74 </test> | |
| 75 <!-- TEST 2 --> | |
| 76 <test expect_num_outputs="4"> | |
| 77 <param name="infile" value="input01.fasta.gz"/> | |
| 78 <conditional name="sorted_table"> | |
| 79 <param name="sorted_table_option" value="yes_with_default"/> | |
| 80 </conditional> | |
| 81 <output name="fastk_out" ftype="tar"> | |
| 82 <assert_contents> | |
| 83 <has_archive_member path="./outfiles/output.hist"/> | |
| 84 <has_archive_member path="./outfiles/ktabfiles/output.ktab"/> | |
| 85 </assert_contents> | |
| 86 </output> | |
| 87 <output name="tabex_hist" file="test02.tabex.txt"/> | |
| 88 </test> | |
| 89 <!-- TEST 3 --> | |
| 90 <test expect_num_outputs="4"> | |
| 91 <param name="infile" value="input01.fasta.gz"/> | |
| 92 <conditional name="sorted_table"> | |
| 93 <param name="sorted_table_option" value="yes_with_custom"/> | |
| 94 <param name="sorted_table_cutoff" value="5"/> | |
| 95 </conditional> | |
| 96 <output name="fastk_out" ftype="tar"> | |
| 97 <assert_contents> | |
| 98 <has_archive_member path="./outfiles/output.hist"/> | |
| 99 <has_archive_member path="./outfiles/ktabfiles/output.ktab"/> | |
| 100 </assert_contents> | |
| 101 </output> | |
| 102 <output name="tabex_hist" file="test03.tabex.txt"/> | |
| 103 </test> | |
| 104 </tests> | |
| 105 <help><![CDATA[ | |
| 106 FastK is a k‑mer counter that is optimized for processing high quality DNA assembly data sets such as those produced with an Illumina instrument or a PacBio run in HiFi mode. | |
| 107 | |
| 108 The input data can be in CRAM, BAM, SAM, fasta, or fastq files. | |
| 109 | |
| 110 FastK produces the following outputs: | |
| 111 | |
| 112 1. FastK hist: file in binary format containing histogram information detailing the frequency of occurrence for each k‑mer within the dataset. | |
| 113 | |
| 114 2. A Tabex txt file comprising a table of k‑mer/count pairs, sorted lexicographically on the k‑mer sequence, followingthe order a < c < g < t | |
| 115 | |
| 116 3. A tar file comprising of hidden .ktab files that can be used for downstream FASTK tools. | |
| 117 | |
| 118 | |
| 119 ]]></help> | |
| 120 <expand macro="citations"/> | |
| 121 </tool> |
