Class: GTFAnnotation
Create object containing subset of elements from GTFAnnotation
object
NewObj = getSubset(AnnotObj,StartPos,EndPos)
NewObj = getSubset(AnnotObj,Subset)
NewObj = getSubset(___,Name,Value)
returns NewObj
= getSubset(AnnotObj
,StartPos
,EndPos
)NewObj
,
a new object containing a subset of the elements from AnnotObj
that
falls within each reference sequence range specified by StartPos
and EndPos
.
returns NewObj
= getSubset(AnnotObj
,Subset
)NewObj
,
a new object containing a subset of elements specified by Subset
,
a vector of integers.
returns NewObj
= getSubset(___,Name,Value
)NewObj
,
a new object containing a subset of the elements from AnnotObj
,
using any of the input arguments from the previous syntaxes and additional
options specified by one or more Name,Value
pair
arguments.
|
Object of the |
|
Nonnegative integer specifying the start of a range in each
reference sequence in |
|
Nonnegative integer specifying the end of a range in each reference
sequence in |
|
Vector of positive integers less than or equal to the number
of entries in the object. Use the vector |
Specify optional
comma-separated pairs of Name,Value
arguments. Name
is
the argument name and Value
is the corresponding value.
Name
must appear inside quotes. You can specify several name and value
pair arguments in any order as
Name1,Value1,...,NameN,ValueN
.
|
Character vector, string, string vector, or cell array of character vectors specifying one or
more reference sequences in |
|
Character vector, string, string vector, or cell array of character vectors specifying one or
more features in |
|
Character vector, string, string vector, or cell array of character vectors specifying one or
more genes in |
|
Character vector, string, string vector, or cell array of character vectors specifying one or
more transcripts in |
|
Minimum number of base positions that an annotation must overlap
in the range, to be included in
Default: |
|
Object of the |
Construct a GTFAnnotation
object using
a GTF-formatted file that is provided with Bioinformatics Toolbox™.
GTFAnnotObj = GTFAnnotation('hum37_2_1M.gtf');
Create a subset of the data containing only CDS features.
subsetGTF = getSubset(GTFAnnotObj,'Feature','CDS')
subsetGTF = GTFAnnotation with properties: FieldNames: {1x11 cell} NumEntries: 92
Construct a GTFAnnotation
object using
a GTF-formatted file that is provided with Bioinformatics Toolbox.
GTFAnnotObj = GTFAnnotation('hum37_2_1M.gtf');
Retrieve a subset of data from the first to fifth elements of GTFAnnotObj
.
subsetGTF1 = getSubset(GTFAnnotObj,[1:5]) subsetGTF1 = GTFAnnotation with properties: FieldNames: {1x11 cell} NumEntries: 5
Retrieve only the first, fifth and eighth elements of GTFAnnotObj
.
subsetGTF2 = getSubset(GTFAnnotObj,[1 5 8]) subsetGTF2 = GTFAnnotation with properties: FieldNames: {1x11 cell} NumEntries: 3
The getSubset
method selects
annotations from the range specified by StartPos
and EndPos
for
each reference sequence in AnnotObj
unless you
use the 'Reference'
name-value pair argument
to limit the reference sequences.
After creating a subsetted object, you can access
the number of entries, range of reference sequences covered by annotations,
field names, and reference names. To access the values of all fields,
create a structure of the data using the getData
method.
getData (GTFAnnotation)
| getFeatureNames (GTFAnnotation)
| getGeneNames (GTFAnnotation)
| getGenes (GTFAnnotation)
| getIndex (GTFAnnotation)
| getRange (GTFAnnotation)
| getReferenceNames (GTFAnnotation)
| getSegments (GTFAnnotation)
| getSubset (GTFAnnotation)
| getTranscripts (GTFAnnotation)
| GFFAnnotation
| GTFAnnotation