root/galaxy-central/eggs/bx_python-0.5.0_dev_f74aec067563-py2.6-macosx-10.6-universal-ucs2.egg/EGG-INFO/scripts/wiggle_to_simple.py @ 3

リビジョン 3, 0.5 KB (コミッタ: kohda, 14 年 前)

Install Unix tools  http://hannonlab.cshl.edu/galaxy_unix_tools/galaxy.html

行番号 
1#!/usr/bin/python2.6
2
3"""
4Read a wiggle track and print out a series of lines containing
5"chrom position score". Ignores track lines, handles bed, variableStep
6and fixedStep wiggle lines.
7"""
8
9import psyco_full
10
11import sys
12import bx.wiggle
13
14if len( sys.argv ) > 1: in_file = open( sys.argv[1] )
15else: in_file = sys.stdin
16
17if len( sys.argv ) > 2: out_file = open( sys.argv[2], "w" )
18else: out_file = sys.stdout
19
20for fields in bx.wiggle.Reader( in_file ):
21    print " ".join( map( str, fields ) )
22
23in_file.close()
24out_file.close()
Note: リポジトリブラウザについてのヘルプは TracBrowser を参照してください。