Mercurial > repos > rmarenco > hubarchivecreator
comparison Gtf.py @ 26:df42241d3731 draft
planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit c11beb58525fe6453a2180fe7783f6e8b0151901-dirty
author | yating-l |
---|---|
date | Mon, 03 Jul 2017 17:30:20 -0400 |
parents | 2677f1899aa8 |
children |
comparison
equal
deleted
inserted
replaced
25:99dad5f9444c | 26:df42241d3731 |
---|---|
26 self.name_gtf = data_gtf["name"] | 26 self.name_gtf = data_gtf["name"] |
27 self.priority = data_gtf["order_index"] | 27 self.priority = data_gtf["order_index"] |
28 self.track_color = data_gtf["track_color"] | 28 self.track_color = data_gtf["track_color"] |
29 # TODO: Think about how to avoid repetition of the group_name everywhere | 29 # TODO: Think about how to avoid repetition of the group_name everywhere |
30 self.group_name = data_gtf["group_name"] | 30 self.group_name = data_gtf["group_name"] |
31 self.database = data_gtf["database"] | |
31 if data_gtf["long_label"]: | 32 if data_gtf["long_label"]: |
32 self.long_label = data_gtf["long_label"] | 33 self.long_label = data_gtf["long_label"] |
33 else: | 34 else: |
34 self.long_label = self.name_gtf | 35 self.long_label = self.name_gtf |
35 #print "Creating TrackHub GTF from (falsePath: %s; name: %s)" % ( self.input_gtf_false_path, self.name_gtf) | 36 #print "Creating TrackHub GTF from (falsePath: %s; name: %s)" % ( self.input_gtf_false_path, self.name_gtf) |
64 subtools.bedToBigBed(sorted_bigGenePred_file.name, | 65 subtools.bedToBigBed(sorted_bigGenePred_file.name, |
65 self.chromSizesFile.name, | 66 self.chromSizesFile.name, |
66 bigBedFile.name, | 67 bigBedFile.name, |
67 autoSql=auto_sql_option, | 68 autoSql=auto_sql_option, |
68 typeOption='bed12+8', | 69 typeOption='bed12+8', |
69 tab=True) | 70 tab=True, |
71 extraIndex='name') | |
70 | 72 |
71 | 73 |
72 # Create the Track Object | 74 # Create the Track Object |
73 self.createTrack(file_path=trackName, | 75 self.createTrack(file_path=trackName, |
74 track_name=trackName, | 76 track_name=trackName, |
75 long_label=self.long_label, track_type='bigGenePred', | 77 long_label=self.long_label, track_type='bigGenePred', |
76 visibility='dense', priority=self.priority, | 78 visibility='dense', priority=self.priority, |
77 track_file=myBigBedFilePath, | 79 track_file=myBigBedFilePath, |
78 track_color=self.track_color, | 80 track_color=self.track_color, |
79 group_name=self.group_name) | 81 group_name=self.group_name, |
82 database=self.database) | |
80 | 83 |
81 # TODO: Use Logging instead of print | 84 # TODO: Use Logging instead of print |
82 if modified_gtf.is_modified: | 85 if modified_gtf.is_modified: |
83 print("- Warning: Gtf %s created with a modified version of your Gtf because of start/end coordinates issues." | 86 print("- Warning: Gtf %s created with a modified version of your Gtf because of start/end coordinates issues." |
84 % self.name_gtf) | 87 % self.name_gtf) |