PageRenderTime 26ms CodeModel.GetById 23ms RepoModel.GetById 0ms app.codeStats 0ms

/tools/fasta_tools/fasta_compute_length.xml

https://bitbucket.org/ialbert/galaxy-genetrack
XML | 51 lines | 39 code | 12 blank | 0 comment | 0 complexity | 37810fd3b2412a1e7a1f69aef68faef3 MD5 | raw file
  1. <tool id="fasta_compute_length" name="Compute sequence length">
  2. <description></description>
  3. <command interpreter="python">fasta_compute_length.py $input $output $keep_first</command>
  4. <inputs>
  5. <param name="input" type="data" format="fasta" label="Compute length for these sequences"/>
  6. <param name="keep_first" type="integer" size="5" value="0" label="How many title characters to keep?" help="'0' = keep the whole thing"/>
  7. </inputs>
  8. <outputs>
  9. <data name="output" format="tabular"/>
  10. </outputs>
  11. <tests>
  12. <test>
  13. <param name="input" value="454.fasta" />
  14. <param name="keep_first" value="0"/>
  15. <output name="output" file="fasta_tool_compute_length_1.out" />
  16. </test>
  17. <test>
  18. <param name="input" value="extract_genomic_dna_out1.fasta" />
  19. <param name="keep_first" value="0"/>
  20. <output name="output" file="fasta_tool_compute_length_2.out" />
  21. </test>
  22. <test>
  23. <param name="input" value="454.fasta" />
  24. <param name="keep_first" value="14"/>
  25. <output name="output" file="fasta_tool_compute_length_3.out" />
  26. </test>
  27. </tests>
  28. <help>
  29. **What it does**
  30. This tool counts the length of each fasta sequence in the file. The output file has two columns per line (separated by tab): fasta titles and lengths of the sequences. The option *How many characters to keep?* allows to select a specified number of letters from the beginning of each FASTA entry.
  31. -----
  32. **Example**
  33. Suppose you have the following FASTA formatted sequences from a Roche (454) FLX sequencing run::
  34. &gt;EYKX4VC02EQLO5 length=108 xy=1826_0455 region=2 run=R_2007_11_07_16_15_57_ TCCGCGCCGAGCATGCCCATCTTGGATTCCGGCGCGATGACCATCGCCCGCTCCACCACG TTCGGCCGGCCCTTCTCGTCGAGGAATGACACCAGCGCTTCGCCCACG &gt;EYKX4VC02D4GS2 length=60 xy=1573_3972 region=2 run=R_2007_11_07_16_15_57_ AATAAAACTAAATCAGCAAAGACTGGCAAATACTCACAGGCTTATACAATACAAATGTAAfa
  35. Running this tool while setting **How many characters to keep?** to **14** will produce this::
  36. EYKX4VC02EQLO5 108
  37. EYKX4VC02D4GS2 60
  38. </help>
  39. </tool>