Generation of wig files from mapreads output

These steps can be used to generate variable format wig files (for viewing on browsers such as Affymetrix Integrated genome browser) from mapreads output. There are several steps, but they are quite simple.

For example, lets say we get as output from mapreads (or from ABI small-rna pipeline mapping), the file test.out

1. Generate a tab-delimited info file using mapreads_interpreter, giving as input test.out and the reference file mapped against reference.fasta

mapreads_interpreter test.out reference.fasta > test.info

2. Reorient the info file using grab_fields script.

grab_fields test.info > test.start

(When running this with ABI small-rna pipeline output, grab_fields_SREK test.info > test.start)

3. Convert previous output (.start file) to bed format

mrstart2bed test.start > test.bed

(When running this with ABI small-rna pipeline output, mrstart2bed_SREK test.start > test.bed)

4. Convert bed file into fixed wig format

con2wig_ht1.pl test.bed > test.wig

5. Convert fixed wig format to variable wig format

fixed_to_variable.pl test.wig test.var.wig