Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • cascoamarillo
    Senior Member
    • Oct 2010
    • 164

    #1

    Get antisense mapped reads

    Hi,

    I'm looking for some workflow to obtain the reads which are mapped to the antisense features (gff) of a reference.
    I started using HTseq_count (which is a great tool), that takes my sam and gff files, and with the obtion -s no/yes I do obtain (no stranded minus stranded) the the number of antisense reads; but I need the reads themselves (sam or fasta). So, is there a way from a sam file (output from HTseq - no stranded reads) to take off a subset of reads (stranded sam output) and get the final sam file with the antisense pool? Maybe there are better ways to do this.

    Thanks
  • dpryan
    Devon Ryan
    • Jul 2011
    • 3478

    #2
    Have you tried just swapping the strands in the GFF file and then running htseq-count on it (with "-s yes"). If you need the actual reads then just use the "-o" option (possibly followed by grepping the output).

    Comment

    • cascoamarillo
      Senior Member
      • Oct 2010
      • 164

      #3
      Unfortunately, when I try this (get sam-output with option "-s yes" using two strand-swapped GFF files) the sam outputs are completely the same (but the output counts are different, so the GFF files are perfectly swapped). The sam file records all the input sam reads (sense and antisense) that are located within the GFF features. Any more ideas?
      Thanks

      Comment

      • cascoamarillo
        Senior Member
        • Oct 2010
        • 164

        #4
        In other words; is there a way to generate a fasta file from a sam/bam aligment considering if a read overlaps with a GFF feature. I mean, the output sam from HTSeq looks like this:

        Code:
        EAS1745:7:1:13167:1095/1	0	scaffold_665	35984	255	28M	*	0	0	NNNNNNNNNNNNNNNNN	IIIIIIIIIIIIIIIIIIIIIIIIIIII	XA:i:0	MD:Z:28	NM:i:0	XF:Z:no_feature
        EAS1745:7:1:9468:1170/1	0	scaffold_313	108426	255	27M	*	0	0	NNNNNNNNNNNNNNNNNN	IIIIIIIIIIIIIIIIIIIIIIIIIII	XA:i:0	MD:Z:27	NM:i:0	XF:Z:Feature#69
        So I'm only interested in taking the reads with a feature flag (and rule out the no_feature/not_aligned reads). thanks

        Comment

        • dpryan
          Devon Ryan
          • Jul 2011
          • 3478

          #5
          You can filter for "Feature" over "no_feature" and "not_aligned" with a simple grep. For generating a fasta file, I suppose that depends on if you want each entry in the multifasta file to be a read or a covered region. If you want an entry per read, you could probably just pipe the output of your grep command to awk or sed (or perl or something else if you prefer). Otherwise, you'd need to do a pileup and process that (it's likely someone has already written a script to do that if you do a bit of searching). You could also N-mask non-covered regions in a similar manner, if that's useful for you.

          Comment

          • cascoamarillo
            Senior Member
            • Oct 2010
            • 164

            #6
            Thanks for the advise.
            I'm fine with the reads in a fasta file. Though I'm not an expert in this thing, this seems to work:
            | awk '{OFS="\t"; if($15 != "XF:Z:no_feature") print ">"$1"\n"$10}' - > file.fasta

            Comment

            Latest Articles

            Collapse

            • SEQadmin2
              Multiomic Liquid Biopsy: What DNA/RNA Panels Reveal That DNA Alone Can’t
              by SEQadmin2



              Tumors contain complex mixtures of cell populations that evolve in response to treatment and host-specific factors. Tissue biopsies provide only static snapshots of a tumor’s state. But what if we could follow that evolution over time using a minimally invasive technique?

              Liquid biopsies can detect tumor-derived material circulating in the bloodstream, providing a way to study treatment response, detect emerging resistance, and discover new biomarkers. Circulating
              ...
              10-14-2026, 09:55 AM
            • SEQadmin2
              New Genomics Technologies Take Aim at Long-Standing Limits
              by SEQadmin2


              Researchers using sequencing and genomics tools often have to make trade-offs. They can choose between speed or scale, short reads or long-range information, or targeted panels or a view of the whole transcriptome. New technologies that have been released this year are built to address those tough choices.

              We asked six companies the same four questions to learn about their latest products. The new technologies bring a lot to the table, including rethinking sequencing
              ...
              09-28-2026, 10:25 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by SEQadmin2, 10-22-2026, 11:13 AM
            0 responses
            24 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-22-2026, 10:48 AM
            0 responses
            20 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-15-2026, 10:52 AM
            0 responses
            36 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-14-2026, 05:39 AM
            0 responses
            42 views
            0 reactions
            Last Post SEQadmin2  
            Working...