root/galaxy-central/tools/maf/vcf_to_maf_customtrack.xml

リビジョン 2, 4.9 KB (コミッタ: hatakeyama, 14 年 前)

import galaxy-central

行番号 
1<tool id="vcf_to_maf_customtrack1" name="VCF to MAF Custom Track">
2  <description>for display at UCSC</description>
3  <command interpreter="python">vcf_to_maf_customtrack.py '$out_file1'
4    #if $vcf_source_type.vcf_file
5    '${vcf_source_type.vcf_file[0].vcf_input.dbkey}'
6    #else
7    '?'
8    #end if
9    ${vcf_source_type.vcf_source} -n '$track_name'
10    #for $vcf_repeat in $vcf_source_type.vcf_file
11    '${vcf_repeat.vcf_input}'
12    #if $vcf_source_type.vcf_source == '-p'
13      '${vcf_repeat.population_name}'
14    #end if
15    #end for
16    -g
17  </command>
18  <inputs>
19    <param name="track_name" type="text" label="Custom Track Name" value="Galaxy Custom Track" size="30" />
20    <conditional name="vcf_source_type">
21      <param name="vcf_source" type="select" label="VCF Source Source Type">
22        <option value="-p" selected="true">Per Population (file)</option>
23        <option value="-s">Per Sample</option>
24      </param>
25      <when value="-p">
26        <repeat name="vcf_file" title="VCF population file" min="1">
27          <param format="tabular" name="vcf_input" type="data" label="VCF file"/>
28          <param name="population_name" type="text" label="Name for this population" value=""/>
29        </repeat>
30      </when>
31      <when value="-s">
32        <repeat name="vcf_file" title="VCF sample file" min="1">
33          <param format="tabular" name="vcf_input" type="data" label="VCF file"/>
34          <!-- add column count validator >= 8? -->
35        </repeat>
36      </when>
37    </conditional>
38  </inputs>
39  <outputs>
40    <data format="mafcustomtrack" name="out_file1" />
41  </outputs>
42<!--  <tests>
43    <test>
44      <param name="track_name" value="Galaxy Custom Track"/>
45      <param name="vcf_source" value="Per Population"/>
46      <param name="vcf_input" value="vcf_to_maf_in.vcf" ftype="tabular"/>
47      <param name="population_name" value=""/>
48      <output name="out_file1" file="vcf_to_maf_population_out.mafcustomtrack"/>
49    </test>
50    <test>
51      <param name="track_name" value="Galaxy Custom Track"/>
52      <param name="vcf_source" value="Per Sample"/>
53      <param name="vcf_input" value="vcf_to_maf_in.vcf" ftype="tabular"/>
54      <output name="out_file1" file="vcf_to_maf_sample_out.mafcustomtrack"/>
55    </test>
56  </tests> -->
57  <help>
58**What it does**
59
60This tool converts a Variant Call Format (VCF) file into a Multiple Alignment Format (MAF) custom track file suitable for display at genome browsers.
61
62This file should be used for display purposes only (e.g as a UCSC Custom Track). Performing an analysis using the output created by this tool as input is not recommended; the source VCF file should be used when performing an analysis.
63
64*Unknown nucleotides* are represented as '*' as required to allow the display to draw properly; these include e.g. reference bases which appear before a deletion and are not available without querying the original reference sequence.
65
66**Example**
67
68Starting with a VCF::
69
70  ##fileformat=VCFv3.3
71  ##fileDate=20090805
72  ##source=myImputationProgramV3.1
73  ##reference=1000GenomesPilot-NCBI36
74  ##phasing=partial
75  ##INFO=NS,1,Integer,"Number of Samples With Data"
76  ##INFO=DP,1,Integer,"Total Depth"
77  ##INFO=AF,-1,Float,"Allele Frequency"
78  ##INFO=AA,1,String,"Ancestral Allele"
79  ##INFO=DB,0,Flag,"dbSNP membership, build 129"
80  ##INFO=H2,0,Flag,"HapMap2 membership"
81  ##FILTER=q10,"Quality below 10"
82  ##FILTER=s50,"Less than 50% of samples have data"
83  ##FORMAT=GT,1,String,"Genotype"
84  ##FORMAT=GQ,1,Integer,"Genotype Quality"
85  ##FORMAT=DP,1,Integer,"Read Depth"
86  ##FORMAT=HQ,2,Integer,"Haplotype Quality"
87  #CHROM  POS ID  REF ALT QUAL    FILTER  INFO    FORMAT  NA00001 NA00002 NA00003
88  20  14370   rs6054257   G   A   29  0   NS=3;DP=14;AF=0.5;DB;H2 GT:GQ:DP:HQ 0|0:48:1:51,51  1|0:48:8:51,51  1/1:43:5:-1,-1
89  20  17330   .   T   A   3   q10 NS=3;DP=11;AF=0.017 GT:GQ:DP:HQ 0|0:49:3:58,50  0|1:3:5:65,3    0/0:41:3:-1,-1
90  20  1110696 rs6040355   A   G,T 67  0   NS=2;DP=10;AF=0.333,0.667;AA=T;DB   GT:GQ:DP:HQ 1|2:21:6:23,27  2|1:2:0:18,2    2/2:35:4:-1,-1
91  20  1230237 .   T   .   47  0   NS=3;DP=13;AA=T GT:GQ:DP:HQ 0|0:54:7:56,60  0|0:48:4:51,51  0/0:61:2:-1,-1
92  20  1234567 microsat1   G   D4,IGA  50  0   NS=3;DP=9;AA=G  GT:GQ:DP    0/1:35:4    0/2:17:2    1/1:40:3
93 
94
95
96
97Under the following conditions: **VCF Source type:** *Per Population (file)*, **Name for this population:** *CHB+JPT*
98Results in the following MAF custom track::
99
100  track name="Galaxy Custom Track" visibility=pack
101  ##maf version=1
102  a score=0
103  s hg18.chr20  14369 1 + 14370 G
104  s CHB+JPT_1.1     0 1 +     1 A
105 
106  a score=0
107  s hg18.chr20  17329 1 + 17330 T
108  s CHB+JPT_1.2     0 1 +     1 A
109 
110  a score=0
111  s hg18.chr20  1110695 1 + 1110696 A
112  s CHB+JPT_1.3       0 1 +       1 G
113  s CHB+JPT_2.3       0 1 +       1 T
114 
115  a score=0
116  s hg18.chr20  1230236 1 + 1230237 T
117  s CHB+JPT_1.4       0 1 +       1 .
118 
119  a score=0
120  s hg18.chr20  1234565 5 + 1234572 *G--***
121  s CHB+JPT_1.5       0 1 +       1 *------
122  s CHB+JPT_2.5       0 7 +       7 *GGA***
123 
124
125    </help>
126</tool>
127
Note: リポジトリブラウザについてのヘルプは TracBrowser を参照してください。