Strand in sgr files

8 views
Skip to first unread message

Steve Piccolo

unread,
Feb 1, 2011, 6:10:11 PM2/1/11
to gnumap...@googlegroups.com
The SAM output files in GNUMAP contain strand information (positive or negative). But no such information is available in the SGR files. I'm assuming this is because the Integrated Genome Browser doesn't want that information.

I am using SGR files as a simple way to count the number of reads that were mapped to a given part of the genome (i.e., gene). And I would like to know the strand information also. I suppose I could parse the SAM files, but I'm not sure how I would process the data to get the same # of reads that are listed in the SGR files. Any suggestions on how to do this? Or any suggestions for a simple workaround?

Thanks,
-Steve

W. Evan Johnson

unread,
Feb 1, 2011, 6:18:41 PM2/1/11
to gnumap...@googlegroups.com
Steve,

One other important thing to consider here. Often, researchers will reverse-transcribe their RNA to make cDNA before sequencing. If this is the case, then all strand information is lost because the sequencer can sequence either side of the cDNA. Just want to point out that you need to know the experimental protocol to see if strand information is even important in your case.

Evan

Nathan Clement

unread,
Feb 2, 2011, 7:01:41 PM2/2/11
to gnumap...@googlegroups.com
Steve,

The reads in the sam file will probably be your best bet--since they contain the correct strand information. Remembering all of this information would cause GNUMAP's memory footprint to double...which would be sub-optimal.

If you want to count the reads at a given position, I've previously written a simple script that will sort a SAM file based on chromosome name and position (I couldn't get the bash-native "sort" function to work properly, so I wrote my own in C++). I'll attach that here so you can use it. If you first sort them by position, you can then either look in the file for the correct position you want or grep for it (I prefer the second option--less sequences to go through).

Other than that, I'm not sure of any workarounds. I'm looking to implement a flag that will output all SAM records that have a posterior probability over a given cutoff. This would make your SAM analysis nearly equal to what the SGR file will tell you.

Nathan

samsort.cpp
Reply all
Reply to author
Forward
0 new messages