1Ace::Sequence::FeatureLUissetr(3C)ontributed Perl DocumeAnctea:t:iSoenquence::FeatureList(3)
2
3
4

NAME

6       Ace::Sequence::FeatureList - Lightweight Access to Features
7

SYNOPSIS

9           # get a megabase from the middle of chromosome I
10           $seq = Ace::Sequence->new(-name   => 'CHROMOSOME_I,
11                                     -db     => $db,
12                                     -offset => 3_000_000,
13                                     -length => 1_000_000);
14
15           # find out what's there
16           $list = $seq->feature_list;
17
18           # Scalar context: count all the features
19           $feature_count = $list->types;
20
21           # Array context: list all the feature types
22           @feature_types = $list->types;
23
24           # Scalar context, 1 argument.  Count this type
25           $gene_cnt = $list->types('Predicted_gene');
26           print "There are $gene_cnt genes here.\n";
27
28           # Array context, 1 argument.  Get list of subtypes
29           @subtypes = $list->types('Predicted_gene');
30
31           # Two arguments. Count type & subtype
32           $genefinder_cnt = $list->types('Predicted_gene','genefinder');
33

DESCRIPTION

35       Ace::Sequence::FeatureList is a small class that provides statistical
36       information about sequence features.  From it you can obtain summary
37       counts of the features and their types within a selected region.
38

OBJECT CREATION

40       You will not ordinarily create an Ace::Sequence::FeatureList object
41       directly.  Instead, objects will be created by calling a Ace::Sequence
42       object's feature_list() method.  If you wish to create an
43       Ace::Sequence::FeatureList object directly, please consult the source
44       code for the new() method.
45

OBJECT METHODS

47       There are only two methods in Ace::Sequence::FeatureList.
48
49       type()
50           This method has five distinct behaviors, depending on its context
51           and the number of parameters.  Usage should be intuitive
52
53            Context       Arguments       Behavior
54            -------       ---------       --------
55
56            scalar         -none-         total count of features in list
57            array          -none-         list feature types (e.g. "exon")
58            scalar          type          count features of this type
59            array           type          list subtypes of this type
60            -any-       type,subtype      count features of this type & subtype
61
62           For example, this code fragment will count the number of exons
63           present on the list:
64
65             $exon_count = $list->type('exon');
66
67           This code fragment will count the number of exons found by
68           "genefinder":
69
70             $predicted_exon_count = $list->type('exon','genefinder');
71
72           This code fragment will print out all subtypes of "exon" and their
73           counts:
74
75             for my $subtype ($list->type('exon')) {
76                 print $subtype,"\t",$list->type('exon',$subtype),"\n";
77             }
78
79       asString()
80             print $list->asString;
81
82           This dumps the list out in tab-delimited format.  The order of
83           columns is type, subtype, count.
84

SEE ALSO

86       Ace, Ace::Object, Ace::Sequence, Ace::Sequence::Feature, GFF
87

AUTHOR

89       Lincoln Stein <lstein@w3.org> with extensive help from Jean Thierry-
90       Mieg <mieg@kaa.crbm.cnrs-mop.fr>
91
92       Copyright (c) 1999, Lincoln D. Stein
93
94       This library is free software; you can redistribute it and/or modify it
95       under the same terms as Perl itself.  See DISCLAIMER.txt for
96       disclaimers of warranty.
97
98
99
100perl v5.32.0                      2020-07-28     Ace::Sequence::FeatureList(3)
Impressum