/tools/filters/bed2gff.xml

https://bitbucket.org/cistrome/cistrome-harvard/ · XML · 89 lines · 68 code · 21 blank · 0 comment · 0 complexity · df95bb428aa79fc767eeefe9cae46265 MD5 · raw file

  1. <tool id="bed2gff1" name="BED-to-GFF" version="2.0.0">
  2. <description>converter</description>
  3. <command interpreter="python">bed_to_gff_converter.py $input $out_file1</command>
  4. <inputs>
  5. <param format="bed" name="input" type="data" label="Convert this dataset"/>
  6. </inputs>
  7. <outputs>
  8. <data format="gff" name="out_file1" />
  9. </outputs>
  10. <tests>
  11. <test>
  12. <param name="input" value="9.bed"/>
  13. <output name="out_file1" file="bed2gff_out.gff"/>
  14. </test>
  15. </tests>
  16. <help>
  17. **What it does**
  18. This tool converts data from BED format to GFF format (scroll down for format description).
  19. --------
  20. **Example**
  21. The following data in BED format::
  22. chr28 346187 388197 BC114771 0 + 346187 388197 0 9 144,81,115,63,155,96,134,105,112, 0,24095,26190,31006,32131,33534,36994,41793,41898,
  23. Will be converted to GFF (**note** that the start coordinate is incremented by 1)::
  24. ##gff-version 2
  25. ##bed_to_gff_converter.py
  26. chr28 bed2gff mRNA 346188 388197 0 + . mRNA BC114771;
  27. chr28 bed2gff exon 346188 346331 0 + . exon BC114771;
  28. chr28 bed2gff exon 370283 370363 0 + . exon BC114771;
  29. chr28 bed2gff exon 372378 372492 0 + . exon BC114771;
  30. chr28 bed2gff exon 377194 377256 0 + . exon BC114771;
  31. chr28 bed2gff exon 378319 378473 0 + . exon BC114771;
  32. chr28 bed2gff exon 379722 379817 0 + . exon BC114771;
  33. chr28 bed2gff exon 383182 383315 0 + . exon BC114771;
  34. chr28 bed2gff exon 387981 388085 0 + . exon BC114771;
  35. chr28 bed2gff exon 388086 388197 0 + . exon BC114771;
  36. ------
  37. .. class:: informark
  38. **About formats**
  39. **BED format** Browser Extensible Data format was designed at UCSC for displaying data tracks in the Genome Browser. It has three required fields and several additional optional ones:
  40. The first three BED fields (required) are::
  41. 1. chrom - The name of the chromosome (e.g. chr1, chrY_random).
  42. 2. chromStart - The starting position in the chromosome. (The first base in a chromosome is numbered 0.)
  43. 3. chromEnd - The ending position in the chromosome, plus 1 (i.e., a half-open interval).
  44. The additional BED fields (optional) are::
  45. 4. name - The name of the BED line.
  46. 5. score - A score between 0 and 1000.
  47. 6. strand - Defines the strand - either '+' or '-'.
  48. 7. thickStart - The starting position where the feature is drawn thickly at the Genome Browser.
  49. 8. thickEnd - The ending position where the feature is drawn thickly at the Genome Browser.
  50. 9. reserved - This should always be set to zero.
  51. 10. blockCount - The number of blocks (exons) in the BED line.
  52. 11. blockSizes - A comma-separated list of the block sizes. The number of items in this list should correspond to blockCount.
  53. 12. blockStarts - A comma-separated list of block starts. All of the blockStart positions should be calculated relative to chromStart. The number of items in this list should correspond to blockCount.
  54. 13. expCount - The number of experiments.
  55. 14. expIds - A comma-separated list of experiment ids. The number of items in this list should correspond to expCount.
  56. 15. expScores - A comma-separated list of experiment scores. All of the expScores should be relative to expIds. The number of items in this list should correspond to expCount.
  57. **GFF format** General Feature Format is a format for describing genes and other features associated with DNA, RNA and Protein sequences. GFF lines have nine tab-separated fields::
  58. 1. seqname - Must be a chromosome or scaffold.
  59. 2. source - The program that generated this feature.
  60. 3. feature - The name of this type of feature. Some examples of standard feature types are "CDS", "start_codon", "stop_codon", and "exon".
  61. 4. start - The starting position of the feature in the sequence. The first base is numbered 1.
  62. 5. end - The ending position of the feature (inclusive).
  63. 6. score - A score between 0 and 1000. If there is no score value, enter ".".
  64. 7. strand - Valid entries include '+', '-', or '.' (for don't know/care).
  65. 8. frame - If the feature is a coding exon, frame should be a number between 0-2 that represents the reading frame of the first base. If the feature is not a coding exon, the value should be '.'.
  66. 9. group - All lines with the same group are linked together into a single item.
  67. </help>
  68. </tool>