Main Content

getFeatureNames

Retrieve unique feature names from GTFAnnotation or GFFAnnotation object

Description

example

Features = getFeatureNames(AnnotObj) returns Features, a cell array of character vectors specifying the unique feature names associated with annotations in AnnotObj.

Examples

collapse all

Construct a GTFAnnotation object from a GTF-formatted file that is provided with Bioinformatics Toolbox™, and then retrieve the feature names from the annotation object.

Construct a GTFAnnotation object from a GTF file.

GTFAnnotObj = GTFAnnotation('hum37_2_1M.gtf');

Retrieve feature names from the annotation object.

featureNames = getFeatureNames(GTFAnnotObj)
featureNames = 4x1 cell
    {'CDS'        }
    {'exon'       }
    {'start_codon'}
    {'stop_codon' }

Construct a GFFAnnotation object from a GFF-formatted file that is provided with Bioinformatics Toolbox™, and then retrieve the feature names from the annotation object.

Construct a GFFAnnotation object from a GFF file.

GFFAnnotObj = GFFAnnotation('tair8_1.gff');

Retrieve feature names for the annotation object.

featureNames = getFeatureNames(GFFAnnotObj)
featureNames = 14x1 cell
    {'CDS'                      }
    {'exon'                     }
    {'five_prime_UTR'           }
    {'gene'                     }
    {'mRNA'                     }
    {'miRNA'                    }
    {'ncRNA'                    }
    {'protein'                  }
    {'pseudogene'               }
    {'pseudogenic_exon'         }
    {'pseudogenic_transcript'   }
    {'tRNA'                     }
    {'three_prime_UTR'          }
    {'transposable_element_gene'}

Input Arguments

collapse all

Feature annotations, specified as a GTFAnnotation or GFFAnnotation object.

Output Arguments

collapse all

Unique feature names associated with annotations in AnnotObj, returned as a cell array of character vectors.

Version History

Introduced in R2011b