Mercurial > repos > rmarenco > hubarchivecreator
comparison BigWig.py @ 23:2677f1899aa8 draft
planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 07210e24fe7d22f5dfc84061310280f67f781fb1-dirty
author | yating-l |
---|---|
date | Tue, 09 May 2017 15:42:43 -0400 |
parents | c02720d1afee |
children | fcc1021bd496 |
comparison
equal
deleted
inserted
replaced
22:7ddf651457df | 23:2677f1899aa8 |
---|---|
19 self.name_bigwig = data_bigwig["name"] | 19 self.name_bigwig = data_bigwig["name"] |
20 self.priority = data_bigwig["order_index"] | 20 self.priority = data_bigwig["order_index"] |
21 self.track_color = data_bigwig["track_color"] | 21 self.track_color = data_bigwig["track_color"] |
22 # TODO: Think about how to avoid repetition of the group_name everywhere | 22 # TODO: Think about how to avoid repetition of the group_name everywhere |
23 self.group_name = data_bigwig["group_name"] | 23 self.group_name = data_bigwig["group_name"] |
24 | 24 if data_bigwig["long_label"]: |
25 self.long_label = data_bigwig["long_label"] | |
26 else: | |
27 self.long_label = self.name_bigwig | |
25 #print "Creating TrackHub BigWig from (falsePath: %s; name: %s)" % ( self.input_bigwig_path, self.name_bigwig ) | 28 #print "Creating TrackHub BigWig from (falsePath: %s; name: %s)" % ( self.input_bigwig_path, self.name_bigwig ) |
26 | 29 |
27 trackName = "".join( ( self.name_bigwig, ".bigwig" ) ) | 30 trackName = "".join( ( self.name_bigwig, ".bigwig" ) ) |
28 | 31 |
29 myBigWigFilePath = os.path.join(self.myTrackFolderPath, trackName) | 32 myBigWigFilePath = os.path.join(self.myTrackFolderPath, trackName) |
30 shutil.copy(self.input_bigwig_path, myBigWigFilePath) | 33 shutil.copy(self.input_bigwig_path, myBigWigFilePath) |
31 | 34 |
32 # Create the Track Object | 35 # Create the Track Object |
33 self.createTrack(file_path=trackName, | 36 self.createTrack(file_path=trackName, |
34 track_name=trackName, | 37 track_name=trackName, |
35 long_label=self.name_bigwig, | 38 long_label=self.long_label, |
36 track_type='bigWig', visibility='full', | 39 track_type='bigWig', visibility='full', |
37 priority=self.priority, | 40 priority=self.priority, |
38 track_file=myBigWigFilePath, | 41 track_file=myBigWigFilePath, |
39 track_color=self.track_color, | 42 track_color=self.track_color, |
40 group_name=self.group_name) | 43 group_name=self.group_name) |