Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Blast raw score calculation

    Hello,

    I know this sounds strange but I am having problems to validate the BLAST raw alignment scores (not the bit scores). Here an example alignment:

    -------------------------------------------------------

    Query: 100009 (Length=100)

    Hit: NZ_ABBZ01004690 gi|153879981|ref|NZ_ABBZ01004690.1| Beggiatoa sp. PS, whole genome shotgun sequence
    Length=280

    Score = 176 bits (194), Expected = 6e-42
    Identities = 99/100 (99%), Gaps = 0/100 (0%)
    Strand=Plus/Minus

    TCTGTTCTGTTCCATTGATCTATATCTCTGTTTTGGTACCAGTACCATGCTGTTTTGGTTACTGTAGCCTTGTAGTATAGTTTGAAGTCAGGTAGCGTGA
    ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ||||
    TCTGTTCTGTTCCATTGATCTATATCTCTGTTTTGGTACCAGTACCATGCTGTTTTGGTTACTGTAGCCTTGTAGTATAGTTTGAAGTCAGGTAGTGTGA

    -------------------------------------------------------

    My scoring matrix is:
    match: 2
    mismatch: -3
    gap open: 5
    gap extension: 2

    Following the formula from the NCBI web site http://www.ncbi.nlm.nih.gov/Educatio...t_Scores2.html (and what other aligners produce as raw score) this makes

    99*2 - 3 = 195 and not 194 like BLAST says:

    <Hsp_num>1</Hsp_num>
    <Hsp_bit-score>176.213077892943</Hsp_bit-score>
    <Hsp_score>194</Hsp_score>
    <Hsp_evalue>6.28580662796915e-42</Hsp_evalue>
    <Hsp_query-from>1</Hsp_query-from>
    <Hsp_query-to>100</Hsp_query-to>
    <Hsp_hit-from>108</Hsp_hit-from>
    <Hsp_hit-to>9</Hsp_hit-to>
    <Hsp_query-frame>1</Hsp_query-frame>
    <Hsp_hit-frame>-1</Hsp_hit-frame>
    <Hsp_identity>99</Hsp_identity>
    <Hsp_positive>99</Hsp_positive>
    <Hsp_gaps>0</Hsp_gaps>
    <Hsp_align-len>100</Hsp_align-len>

    In fact I noticed that all BLAST raw scores are even! I am using BLAST version 2.2.22+. Do I miss an import point here?

  • #2
    Did you try to use BLAST+ instead? If the problem does occur with BLAST+, I would switch. You might also want to update to the latest BLAST version.

    Comment


    • #3
      Yes, I am using BLAST+. I am currently running the latest version to see whether it makes any difference. Anyhow, this shoudn't be if it is really a bug. I couldn't find anything about it in the change logs from 2.2.22+ to 2.2.24+ so I rather think that it will give the same results with the latest version. What do you mean by "you should switch"?

      Comment


      • #4
        If the raw score is a huge issue for you, you might want to consider alternative alignment programs (switch to an alternative program).
        You could also try to write the NCBI people who wrote the BLAST+ paper.

        Comment


        • #5
          Yes thanks, I counterchecked with the latest BLAST+ version and found the same issue. The raw score is important to me because when I compare different aligners using the same scoring scheme should result in more or less the same alignments with the same raw scores.

          Another point is that BLAST bit scores are calculated from the raw scores. This would mean that also the bit scores are slightly wrong!

          I will write them an email, unfortunately they don't have a developers mailing list at the NCBI...

          Comment


          • #6
            Just to let you know: Here is some evidence on the issue. I checked different versions and engines of NCBI BLAST. This seems to be an optimization in the code that is on purpose. The effect is that raw score can differ up to 3 points from real score.

            blast2.2.24+:

            * * * <Parameters_expect>10000</Parameters_expect>
            * * * <Parameters_sc-match>2</Parameters_sc-match>
            * * * <Parameters_sc-mismatch>-3</Parameters_sc-mismatch>
            * * * <Parameters_gap-open>5</Parameters_gap-open>
            * * * <Parameters_gap-extend>2</Parameters_gap-extend>
            * * * <Parameters_filter>F</Parameters_filter>

            * * * * * * * <Hsp_num>1</Hsp_num>
            * * * * * * * <Hsp_bit-score>176.213077892943</Hsp_bit-score>
            * * * * * * * <Hsp_score>194</Hsp_score>
            * * * * * * * <Hsp_evalue>6.28580662796915e-42</Hsp_evalue>
            * * * * * * * <Hsp_query-from>1</Hsp_query-from>
            * * * * * * * <Hsp_query-to>100</Hsp_query-to>
            * * * * * * * <Hsp_hit-from>108</Hsp_hit-from>
            * * * * * * * <Hsp_hit-to>9</Hsp_hit-to>
            * * * * * * * <Hsp_query-frame>1</Hsp_query-frame>
            * * * * * * * <Hsp_hit-frame>-1</Hsp_hit-frame>
            * * * * * * * <Hsp_identity>99</Hsp_identity>
            * * * * * * * <Hsp_positive>99</Hsp_positive>
            * * * * * * * <Hsp_gaps>0</Hsp_gaps>
            * * * * * * * <Hsp_align-len>100</Hsp_align-len>
            * * * * * * *
            <Hsp_qseq>TCTGTTCTGTTCCATTGATCTATATCTCTGTTTTGGTACCAGTACCATGCTGTTTTGGTTACTGTAGCCTTGTAGTATAGTTTGAAGTCAGGTAGCGTGA</Hsp_qseq>
            * * * * * * *
            <Hsp_hseq>TCTGTTCTGTTCCATTGATCTATATCTCTGTTTTGGTACCAGTACCATGCTGTTTTGGTTACTGTAGCCTTGTAGTATAGTTTGAAGTCAGGTAGTGTGA</Hsp_hseq>
            * * * * * * *
            <Hsp_midline>||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ||||
            </Hsp_midline>

            ================================================================================
            blast2.2.24:

            * * * <Parameters_expect>10000</Parameters_expect>
            * * * <Parameters_sc-match>2</Parameters_sc-match>
            * * * <Parameters_sc-mismatch>-3</Parameters_sc-mismatch>
            * * * <Parameters_gap-open>5</Parameters_gap-open>
            * * * <Parameters_gap-extend>2</Parameters_gap-extend>
            * * * <Parameters_filter>F</Parameters_filter>

            * * * * * * * <Hsp_num>1</Hsp_num>
            * * * * * * * <Hsp_bit-score>176.213</Hsp_bit-score>
            * * * * * * * <Hsp_score>194</Hsp_score>
            * * * * * * * <Hsp_evalue>6.28581e-42</Hsp_evalue>
            * * * * * * * <Hsp_query-from>100</Hsp_query-from>
            * * * * * * * <Hsp_query-to>1</Hsp_query-to>
            * * * * * * * <Hsp_hit-from>9</Hsp_hit-from>
            * * * * * * * <Hsp_hit-to>108</Hsp_hit-to>
            * * * * * * * <Hsp_query-frame>1</Hsp_query-frame>
            * * * * * * * <Hsp_hit-frame>-1</Hsp_hit-frame>
            * * * * * * * <Hsp_identity>99</Hsp_identity>
            * * * * * * * <Hsp_positive>99</Hsp_positive>
            * * * * * * * <Hsp_align-len>100</Hsp_align-len>
            * * * * * * *
            <Hsp_qseq>TCACGCTACCTGACTTCAAACTATACTACAAGGCTACAGTAACCAAAACAGCATGGTACTGGTACCAAAACAGAGATATAGATCAATGGAACAGAACAGA</Hsp_qseq>
            * * * * * * *
            <Hsp_hseq>TCACACTACCTGACTTCAAACTATACTACAAGGCTACAGTAACCAAAACAGCATGGTACTGGTACCAAAACAGAGATATAGATCAATGGAACAGAACAGA</Hsp_hseq>
            * * * * * * *
            <Hsp_midline>|||| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
            </Hsp_midline>

            ================================================================================

            blast2.2.24-legacy:

            * * * <Parameters_expect>10000</Parameters_expect>
            * * * <Parameters_sc-match>2</Parameters_sc-match>
            * * * <Parameters_sc-mismatch>-3</Parameters_sc-mismatch>
            * * * <Parameters_gap-open>5</Parameters_gap-open>
            * * * <Parameters_gap-extend>2</Parameters_gap-extend>
            * * * <Parameters_filter>F</Parameters_filter>

            * * * * * * * <Hsp_num>1</Hsp_num>
            * * * * * * * <Hsp_bit-score>177.115</Hsp_bit-score>
            * * * * * * * <Hsp_score>195</Hsp_score>
            * * * * * * * <Hsp_evalue>3.36455e-42</Hsp_evalue>
            * * * * * * * <Hsp_query-from>100</Hsp_query-from>
            * * * * * * * <Hsp_query-to>1</Hsp_query-to>
            * * * * * * * <Hsp_hit-from>9</Hsp_hit-from>
            * * * * * * * <Hsp_hit-to>108</Hsp_hit-to>
            * * * * * * * <Hsp_query-frame>1</Hsp_query-frame>
            * * * * * * * <Hsp_hit-frame>-1</Hsp_hit-frame>
            * * * * * * * <Hsp_identity>99</Hsp_identity>
            * * * * * * * <Hsp_positive>99</Hsp_positive>
            * * * * * * * <Hsp_align-len>100</Hsp_align-len>
            * * * * * * *
            <Hsp_qseq>TCACGCTACCTGACTTCAAACTATACTACAAGGCTACAGTAACCAAAACAGCATGGTACTGGTACCAAAACAGAGATATAGATCAATGGAACAGAACAGA</Hsp_qseq>
            * * * * * * *
            <Hsp_hseq>TCACACTACCTGACTTCAAACTATACTACAAGGCTACAGTAACCAAAACAGCATGGTACTGGTACCAAAACAGAGATATAGATCAATGGAACAGAACAGA</Hsp_hseq>
            * * * * * * *
            <Hsp_midline>|||| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
            </Hsp_midline>

            Comment

            Latest Articles

            Collapse

            • seqadmin
              Genetic Variation in Immunogenetics and Antibody Diversity
              by seqadmin



              The field of immunogenetics explores how genetic variations influence immune responses and susceptibility to disease. In a recent SEQanswers webinar, Oscar Rodriguez, Ph.D., Postdoctoral Researcher at the University of Louisville, and Ruben Martínez Barricarte, Ph.D., Assistant Professor of Medicine at Vanderbilt University, shared recent advancements in immunogenetics. This article discusses their research on genetic variation in antibody loci, antibody production processes,...
              11-06-2024, 07:24 PM
            • seqadmin
              Choosing Between NGS and qPCR
              by seqadmin



              Next-generation sequencing (NGS) and quantitative polymerase chain reaction (qPCR) are essential techniques for investigating the genome, transcriptome, and epigenome. In many cases, choosing the appropriate technique is straightforward, but in others, it can be more challenging to determine the most effective option. A simple distinction is that smaller, more focused projects are typically better suited for qPCR, while larger, more complex datasets benefit from NGS. However,...
              10-18-2024, 07:11 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by seqadmin, Today, 11:09 AM
            0 responses
            22 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, Today, 06:13 AM
            0 responses
            19 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, 11-01-2024, 06:09 AM
            0 responses
            30 views
            0 likes
            Last Post seqadmin  
            Started by seqadmin, 10-30-2024, 05:31 AM
            0 responses
            21 views
            0 likes
            Last Post seqadmin  
            Working...
            X