root/galaxy-central/tools/genetrack/genetrack_peak_prediction.py

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

import galaxy-central

行番号 
1#!/usr/bin/env python
2
3"""
4Wraps genetrack.scripts.peakpred so the tool can be executed from Galaxy.
5
6usage: %prog input output level sigma mode exclusion strand
7"""
8
9import sys
10from galaxy import eggs
11import pkg_resources
12pkg_resources.require( "GeneTrack" )
13
14from genetrack.scripts import peakpred
15from genetrack import logger
16
17if __name__ == "__main__":
18
19    parser = peakpred.option_parser()
20
21    options, args = parser.parse_args()
22
23    logger.disable(options.verbosity)
24
25    from genetrack import conf
26
27    # trigger test mode
28    if options.test:
29        options.inpname = conf.testdata('test-hdflib-input.gtrack')
30        options.outname = conf.testdata('predictions.bed')
31
32    # missing input file name
33    if not options.inpname and not options.outname:
34        parser.print_help()
35    else:
36        print 'Sigma = %s' % options.sigma
37        print 'Minimum peak = %s' % options.level
38        print 'Peak-to-peak = %s' % options.exclude
39
40        peakpred.predict(options.inpname, options.outname, options)
Note: リポジトリブラウザについてのヘルプは TracBrowser を参照してください。