SEQanswers

Go Back   SEQanswers > Bioinformatics > Bioinformatics



Similar Threads
Thread Thread Starter Forum Replies Last Post
htseq-count for sam and gff3 sofia17 RNA Sequencing 45 11-04-2016 03:32 PM
Error with GTF file when using htseq-count MDonlin Bioinformatics 13 01-13-2015 08:29 AM
htseq-count paolo.kunder Bioinformatics 10 10-22-2014 04:45 AM
Strange error when using htseq-count shhuang Bioinformatics 13 11-19-2012 12:40 AM
htseq-count with warning for every read to represent all of zero counts in output hibachings2013 RNA Sequencing 10 07-15-2011 10:19 AM

Reply
 
Thread Tools
Old 03-05-2012, 01:33 AM   #1
Palgrave
Member
 
Location: norway

Join Date: Aug 2011
Posts: 73
Default htseq-count output

Hi,

Is there an easy way to sort the output from htseq-count based on read count. I have mapped my SAM-file onto miRNA-GFF file and basically I want a 2 column output with miRNA and count-number.

Best
Palgrave is offline   Reply With Quote
Old 03-05-2012, 03:17 AM   #2
turnersd
Senior Member
 
Location: Charlottesville, VA

Join Date: May 2011
Posts: 112
Default

Look at the man page for sort:

sort -grk2 htseq.out
turnersd is offline   Reply With Quote
Old 03-05-2012, 04:08 AM   #3
Palgrave
Member
 
Location: norway

Join Date: Aug 2011
Posts: 73
Default

I didnt find it, or maybe I didnt get you?
Where?
Palgrave is offline   Reply With Quote
Old 03-05-2012, 04:20 AM   #4
turnersd
Senior Member
 
Location: Charlottesville, VA

Join Date: May 2011
Posts: 112
Default

At the unix command line, type:

man sort
turnersd is offline   Reply With Quote
Old 03-05-2012, 04:41 AM   #5
Palgrave
Member
 
Location: norway

Join Date: Aug 2011
Posts: 73
Default

and -grk2 is?

When I run htseq-count the reads get sorted in the command line summary, but not in the output. I basically want what gets printed in the terminal when htseq-count is done.
Palgrave is offline   Reply With Quote
Old 03-05-2012, 04:44 AM   #6
turnersd
Senior Member
 
Location: Charlottesville, VA

Join Date: May 2011
Posts: 112
Default

Read the man page for sort and you'll see what -grk2 does.

You have to run the sort command on the output you get from htseq-count. Or else pipe the output to sort.
turnersd is offline   Reply With Quote
Old 03-05-2012, 05:52 AM   #7
Palgrave
Member
 
Location: norway

Join Date: Aug 2011
Posts: 73
Default

Didnt work. Output from sort -grk2 <input_file> was the same as my input. nothing happened.
Palgrave is offline   Reply With Quote
Old 03-05-2012, 07:04 AM   #8
turnersd
Senior Member
 
Location: Charlottesville, VA

Join Date: May 2011
Posts: 112
Default

It should have. I did this on some htseq-count data of my own. I didn't remove the last four lines, that's why the alignment_not_unique and no_features are showing up.


Code:
sdt5z@host:~/htseq$ head gm.htseq.txt 
1/2-SBSRNA4	0
A1BG	0
A1BG-AS1	0
A1CF	0
A2LD1	0
A2M	0
A2ML1	0
A2MP1	0
A4GALT	0
A4GNT	0

sdt5z@host:~/htseq$ sort -grk2 gm.htseq.txt |head
EEF2	19280
alignment_not_unique	15890
no_feature	6321
AES	6173
MKNK2	5681
AP3D1	3406
OAZ1	3385
TCF3	3160
MOBKL2A	2791
BSG	2655
Try separating the arguments (sort -g -r -k2 infile.txt)
turnersd is offline   Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off




All times are GMT -8. The time now is 08:45 AM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Single Sign On provided by vBSSO