Ace::S...eature(3pm)
πΈ Ace::Sequence::Feature β Examine Sequence Feature Tables π
okay bestie, this is the Perl doc for Ace::Sequence::Feature, and I'm gonna walk you through it like we're texting at 2am π¦ β every flag, every method, every single word, no cap.
β¨ NAME β¨
Ace::Sequence::Feature β Examine Sequence Feature Tables π
π SYNOPSIS π
# open database connection and get an Ace::Object sequence
use Ace::Sequence;
# get a megabase from the middle of chromosome I
$seq = Ace::Sequence->new(-name => 'CHROMOSOME_I,
-db => $db,
-offset => 3_000_000,
-length => 1_000_000);
# get all the homologies (a list of Ace::Sequence::Feature objs)
@homol = $seq->features('Similarity');
# Get information about the first one
$feature = $homol[0];
$type = $feature->type;
$subtype = $feature->subtype;
$start = $feature->start;
$end = $feature->end;
$score = $feature->score;
# Follow the target
$target = $feature->info;
# print the target's start and end positions
print $target->start,'-',$target->end, "\n";
(yes that 'CHROMOSOME_I is missing its closing quote in the original β I am NOT touching it, it's canon π)
π DESCRIPTION π
Ace::Sequence::Feature is a subclass of Ace::Sequence::Feature specialized for returning information about particular features in a GFF format feature table. literally what it says on the tin, and it ate π
π OBJECT CREATION π
ngl, you will not ordinarily create an Ace::Sequence::Feature object directly. instead, these little guys get created in response to a feature() call to an Ace::Sequence object. π£
if you truly wish to create an Ace::Sequence::Feature object directly, please consult the source code for the new() method β go read the source bestie, it's giving homework π
π OBJECT METHODS π
most methods are inherited from Ace::Sequence. the following methods are also supported:
𧬠seqname()
$object = $feature->seqname;
Return the ACeDB Sequence object that this feature is attached to. the return value is an Ace::Object of the Sequence class. π₯
this corresponds to the first field of the GFF format and does not necessarily correspond to the Ace::Sequence object from which the feature was obtained (use source_seq() for that β iykyk).
π«Ά source()
π«Ά method()
π«Ά subtype()
$source = $feature->source;
These three methods are all synonyms for the same thing. they return the second field of the GFF format, called "source" in the documentation. this is usually the method or algorithm used to predict the feature, such as "GeneFinder" or "tRNA" scan. π§
to avoid ambiguity and enhance readability, the method() and subtype() synonyms are also recognized. slay.
β¨ feature()
β¨ type()
$type = $feature->type;
These two methods are also synonyms. they return the type of the feature, such as "exon", "similarity" or "Predicted_gene". in the GFF documentation this is called the "feature" field. π
for readability, you can also use type() to fetch the field. obsessed.
π abs_start()
$start = $feature->abs_start;
This method returns the absolute start of the feature within the sequence segment indicated by seqname(). as in the Ace::Sequence method, use start() to obtain the start of the feature relative to its source. π«
π abs_start()
$start = $feature->abs_start;
This method returns the start of the feature relative to the sequence segment indicated by seqname(). as in the Ace::Sequence method, you will more usually use the inherited start() method to obtain the start of the feature relative to its source sequence (the Ace::Sequence from which it was originally derived).
ok bestie, yes, abs_start() shows up twice in this doc. I'm not deleting it, that's just how it is. two entries, both preserved, periodt. π
π abs_end()
$start = $feature->abs_end;
This method returns the end of the feature relative to the sequence segment indicated by seqname(). as in the Ace::Sequence method, you will more usually use the inherited end() method to obtain the end of the feature relative to the Ace::Sequence from which it was derived. πΈ
β score()
$score = $feature->score;
For features that are associated with a numeric score, such as similarities, this returns that value. for other features, this method returns undef. π’
π§ strand()
$strand = $feature->strand;
Returns the strandedness of this feature, either "+1" or "-1". for features that are not stranded, returns 0. π§΅
π reversed()
$reversed = $feature->reversed;
Returns true if the feature is reversed relative to its source sequence. π
πΌοΈ frame()
$frame = $feature->frame;
For features that have a frame, such as a predicted coding sequence, returns the frame, either 0, 1 or 2. for other features, returns undef. π
π group()
π info()
π target()
$info = $feature->info;
These methods (synonyms for one another) return an Ace::Object containing other information about the feature derived from the 8th field of the GFF format, the so-called "group" field. the type of the Ace::Object is dependent on the nature of the feature. the possibilities are shown in the table below: π
(the original says "table" β we're doing it as a list, the facts are identical fr fr)
- Feature Type:
note- Value of Group Field: a
Textobject containing the note.
- Value of Group Field: a
- Feature Type:
similarity- Value of Group Field: an
Ace::Sequence::Homologyobject containing the target and its start/stop positions.
- Value of Group Field: an
- Feature Type:
intron,exon,misc_feature- Value of Group Field: an
Ace::Objectcontaining the gene from which the feature is derived.
- Value of Group Field: an
- Feature Type:
other- Value of Group Field: a
Textobject containing the group data.
- Value of Group Field: a
π¬ asString()
$label = $feature->asString;
Returns a human-readable identifier describing the nature of the feature. the format is: π
$type:$name/$start-$end
for example:
exon:ZK154.3/1-67
This method is also called automatically when the object is treated in a string context. main character energy, honestly. π
π SEE ALSO π
AceAce::ObjectAce::SequenceAce::Sequence::HomolAce::Sequence::FeatureListGFF
π AUTHOR π
Lincoln Stein <lstein@cshl.org> with extensive help from Jean Thierry-Mieg <mieg@kaa.crbm.cnrs-mop.fr>
Copyright (c) 1999, Lincoln D. Stein
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty. π«Ά
and that's a wrap bestie π this page ships with perl v5.42.3, dated 2026-08-19 β go forth and inspect those feature tables, you absolute icon πβ
π¦ where this page comes from
- ubuntu stonking: libace-perl 1.92-14build1 Β· Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms