Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • redse171
    Junior Member
    • Feb 2011
    • 3

    How to read frames in .gff file format

    Hi,

    I need help to understand the .gff file format.
    actually, i want to develop a database for a microorganism based on information in a .gff file. The problem is, i don't understand about the framing parts where it consists of either a dot (.), 0, 1 or 2. I need to understand this so that i could proceed with the necessary data crunching for my input file for the database. i read some information about this in some websites and i tried to do it based on my understanding but still my output is wrong.


    i need to arrange my CDS accordingly. can anyone here help me to explain this clearly? thanks
  • kmcarr
    Senior Member
    • May 2008
    • 1181

    #2
    What is recorded in a GFF (or GTF) file is not frame information; it is codon phase information and only applies to CDS features. Here is the description from the GFF definition page at the GMOD site:
    Column 8: "phase"

    For features of type "CDS", the phase indicates where the feature begins with reference to the reading frame. The phase is one of the integers 0, 1, or 2, indicating the number of bases that should be removed from the beginning of this feature to reach the first base of the next codon. In other words, a phase of "0" indicates that the next codon begins at the first base of the region described by the current line, a phase of "1" indicates that the next codon begins at the second base of this region, and a phase of "2" indicates that the codon begins at the third base of this region. This is NOT to be confused with the frame, which is simply start modulo 3. If there is no phase, put a "." (a period) in this field.

    For forward strand features, phase is counted from the start field. For reverse strand features, phase is counted from the end field.

    The phase is required for all CDS features.
    As the description above says you can determine the reading frame for a transcript by calculating the modulo (remainder) of the start position by 3; for features on the minus strand it would be (chromosome size - start) modulo 3.

    Comment

    • redse171
      Junior Member
      • Feb 2011
      • 3

      #3
      Hi kmcarr,

      Thanks so much for your prompt response.
      i read that one before but not really understand it. with your explanation about modulo, it becomes clearer now. will try doing it and see how it goes.. Thanks

      Comment

      • AlexeyG
        Junior Member
        • Oct 2010
        • 3

        #4
        Hello,

        I thought I'd post a reply here instead of starting a new thread. I'm currently trying to select sequences for CDS features out of a GFF file. And I run into problems when a single mRNA contains several GFFs leading to one and the same protein. An example would be

        chrVII SGD mRNA 726974 727730 . + . Name=YGR118W_mRNA;Parent=58298;ID=58302
        chrVII SGD CDS 726974 727038 . + 0 Name=YGR118W_CDS;Parent=58302;ID=58299;orf_classification=Verified
        chrVII SGD CDS 727358 727730 . + 1 Name=YGR118W_CDS;Parent=58302;ID=58300;orf_classification=Verified
        chrVII SGD intron 727039 727357 . + . Name=YGR118W_intron;Parent=58302;ID=58301;orf_classification=Verified

        From the definition of phase I understand that I have to skip the first base of the second CDS and start translating only after it. But this gives (a) incorrect length of the joint CDS, i.e. not divisible by 3; (b) incorrect translation into amino acids.

        In most cases (except ca. 40 sequences in A.thaliana) a correct result is obtained by simply concatenating the two CDSs without using the phase(s) at all.

        I would appreciate any pointers towards a correct understanding of the phase field, it seems that right now I don't understand its purpose at all.

        Kind regards,
        Alexey

        Comment

        • kmcarr
          Senior Member
          • May 2008
          • 1181

          #5
          Originally posted by AlexeyG View Post
          Hello,

          I thought I'd post a reply here instead of starting a new thread. I'm currently trying to select sequences for CDS features out of a GFF file. And I run into problems when a single mRNA contains several GFFs leading to one and the same protein. An example would be

          chrVII SGD mRNA 726974 727730 . + . Name=YGR118W_mRNA;Parent=58298;ID=58302
          chrVII SGD CDS 726974 727038 . + 0 Name=YGR118W_CDS;Parent=58302;ID=58299;orf_classification=Verified
          chrVII SGD CDS 727358 727730 . + 1 Name=YGR118W_CDS;Parent=58302;ID=58300;orf_classification=Verified
          chrVII SGD intron 727039 727357 . + . Name=YGR118W_intron;Parent=58302;ID=58301;orf_classification=Verified

          From the definition of phase I understand that I have to skip the first base of the second CDS and start translating only after it. But this gives (a) incorrect length of the joint CDS, i.e. not divisible by 3; (b) incorrect translation into amino acids.

          In most cases (except ca. 40 sequences in A.thaliana) a correct result is obtained by simply concatenating the two CDSs without using the phase(s) at all.

          I would appreciate any pointers towards a correct understanding of the phase field, it seems that right now I don't understand its purpose at all.

          Kind regards,
          Alexey
          Alexsy,

          When you say 'skip the first base' I get the feeling you mean you are discarding it when performing the translation. Phase doesn't mean to disregard any of the nucleotides within a CDS, it merely tells you how the reading frame of the overall mRNA relates to that particular coding exon.

          Let's look at your example. The first CDS is 65nt long, divided by 3 (into codons) leaves a remainder of 2nt. You pick up the first nt of the next codon to complete that codon, then continue the translation in CDS #2 from the second position (phase=1). CDS #2 is 373nt long, taken together the complete CDS is 438nt yielding a protein of 146 amino acids (or 145 + stop codon).

          So another way to think of the phase value is how many nt from the 5' end of this exon do I have to use to complete the final codon from the previous exon.

          Comment

          • AlexeyG
            Junior Member
            • Oct 2010
            • 3

            #6
            kmcarr,

            Thank you for spelling the example out for me. I indeed thought that if phase=n, then I have to skip the first n nucleotides. But your last lines puts everything into place.

            The other part of the problem is that I'm still sometimes getting entries like:

            Chr1 TAIR10 CDS 873435 874832 0.0 0 Parent=AT1G03495.1,AT1G03495.1-Protein;

            And in this case it's a lone entry that does not have any neighboring CDS, but which has length of 1397 bp. In reality it should correspond to a gene of 1398 bp, but I guess that I should blame on the errors in my reference sequences.

            Comment

            • kmcarr
              Senior Member
              • May 2008
              • 1181

              #7
              Originally posted by AlexeyG View Post
              kmcarr,

              Thank you for spelling the example out for me. I indeed thought that if phase=n, then I have to skip the first n nucleotides. But your last lines puts everything into place.

              The other part of the problem is that I'm still sometimes getting entries like:

              Chr1 TAIR10 CDS 873435 874832 0.0 0 Parent=AT1G03495.1,AT1G03495.1-Protein;

              And in this case it's a lone entry that does not have any neighboring CDS, but which has length of 1397 bp. In reality it should correspond to a gene of 1398 bp, but I guess that I should blame on the errors in my reference sequences.
              Alexsy,

              No, those coordinates do define a CDS of 1,398nt. Remember that the coordinates are inclusive, so the formula to calculate feature length is:

              end - (start -1) or in your example 874,832 - (873,435 -1) = 1,398

              Comment

              • AlexeyG
                Junior Member
                • Oct 2010
                • 3

                #8
                You're right. But in the previous by accident I posted a BioJava representation of a GFF feature instead of an actual line from the GFF file. Sorry for this mixup. Below is the GFF feature as it's described in the file:

                Chr1 TAIR10 CDS 873436 874832 . + 0 Parent=AT1G03495.1,AT1G03495.1-Protein;

                And the calculation hence:

                In [57]: 874832 - 873436 + 1
                Out[57]: 1397

                Kind regards,
                Alexey.

                Comment

                Latest Articles

                Collapse

                • SEQadmin2
                  Advanced Sequencing Platforms Tackle Neuroscience’s Toughest Genomics Problems
                  by SEQadmin2



                  Genomics studies in neuroscience face a special challenge due to the brain’s complexity and scarcity of samples. Mapping changes in cell type and state using conventional next-generation sequencing methods remains challenging. Advances in technologies like single-cell sequencing, spatial transcriptomics, and long-read sequencing have opened the door to deeper studies of the brain and diseases like Alzheimer’s, amyotrophic lateral sclerosis (ALS), and schizophrenia.
                  ...
                  07-09-2026, 11:10 AM
                • SEQadmin2
                  Cancer Drug Resistance: The Lingering Barrier to Rising Survival
                  by SEQadmin2



                  Cancer survival rates have significantly increased in the last few decades in the United States, reaching a combined 70% 5-year survival rate by 2021. Behind this number, there are years of research to find new therapies, drug targets, and early detection methods. But there is one core challenge that keeps slowing down these advances, and it’s about drug resistance.

                  There is no single reason why many patients don’t respond to treatment as expected. Cancer is...
                  07-08-2026, 05:17 AM
                • GATTACAT
                  Reply to Nine Things a Sample Prep Scientist Thinks About Before Sequencing
                  by GATTACAT
                  Love this - good data definitely starts from good input, and poor input can only give relatively poor data. I particularly like the mention of Nanodrop/absorbance based methods for quantification. It's such a toss up if you'll get an accurate reading or what amounts to a randomly generated number, and a lot of library/sequencing related issues can be traced back to poor quant.
                  07-01-2026, 11:43 AM

                ad_right_rmr

                Collapse

                News

                Collapse

                Topics Statistics Last Post
                Started by SEQadmin2, 07-13-2026, 10:26 AM
                0 responses
                26 views
                0 reactions
                Last Post SEQadmin2  
                Started by SEQadmin2, 07-09-2026, 10:04 AM
                0 responses
                36 views
                0 reactions
                Last Post SEQadmin2  
                Started by SEQadmin2, 07-08-2026, 10:08 AM
                0 responses
                23 views
                0 reactions
                Last Post SEQadmin2  
                Started by SEQadmin2, 07-07-2026, 11:05 AM
                0 responses
                34 views
                0 reactions
                Last Post SEQadmin2  
                Working...