Giter Club home page Giter Club logo

Comments (2)

aryan-9898 avatar aryan-9898 commented on September 12, 2024

Yes, RSEM does require the HI:i: tag in order to correctly process multimappers. The HI tag (HI:i:) is a field in SAM/BAM files that is used to indicate the index of a read within the input file. When processing multimapped reads, RSEM uses the HI tag to keep track of which reads are duplicates, so that they are not counted multiple times.

If the BAM files generated by Hisat2 do not contain the HI tag, you can add it using the samtools command-line tool. The samtools addreplacerg command allows you to add or modify the values of any field in the SAM/BAM header, including the HI tag.

Here's an example of how to add the HI tag to a BAM file using samtools:

samtools addreplacerg -r 'ID:1' -r 'SM:sample' -r 'PL:illumina' -r 'PU:unit' -r 'LB:library' -r 'DT:2023-05-03T12:34:56-0700' -R 'HiSeq2500' -i 'HI' -o output.bam input.bam

In this example, the ID, SM, PL, PU, LB, and DT tags are arbitrary and can be changed to match your specific sample information. The -R option specifies the sequencing platform used to generate the data, and the -i option specifies the name of the index tag to be added (in this case, "HI"). The input BAM file is "input.bam", and the output BAM file with the added HI tag is "output.bam".

from rsem.

apredeus avatar apredeus commented on September 12, 2024

Hi Aryan,

Thank you for your answer! I am confused, however. RSEM appears to support hisat2 as a mapping tool - yet the options used by RSEM do not allow for HI tag to be outputted.

The issue I was having was due to sorting of the BAM file; apparently, transcriptomic files are always read name-sorted by default, and both RSEM and Salmon expect this to be true in order to work correctly. Adding HI tag does not seem to influence the result.

from rsem.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.