3 # BioPerl module for Bio::Matrix::MatrixI
5 # Please direct questions and support issues to <bioperl-l@bioperl.org>
7 # Cared for by Jason Stajich <jason-at-bioperl.org>
9 # Copyright Jason Stajich
11 # You may distribute this module under the same terms as perl itself
13 # POD documentation - main docs before the code
17 Bio::Matrix::MatrixI - An interface for describing a Matrix
25 This is an interface describing how one should be able to interact
26 with a matrix. One can have a lot of information I suppose and this
27 outline won't really work for PWM or PSSMs. We will have to derive a
28 particular interface for those.
34 User feedback is an integral part of the evolution of this and other
35 Bioperl modules. Send your comments and suggestions preferably to
36 the Bioperl mailing list. Your participation is much appreciated.
38 bioperl-l@bioperl.org - General discussion
39 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
43 Please direct usage questions or support issues to the mailing list:
45 I<bioperl-l@bioperl.org>
47 rather than to the module maintainer directly. Many experienced and
48 reponsive experts will be able look at the problem and quickly
49 address it. Please include a thorough description of the problem
50 with code and data examples if at all possible.
54 Report bugs to the Bioperl bug tracking system to help us keep track
55 of the bugs and their resolution. Bug reports can be submitted via
58 https://github.com/bioperl/bioperl-live/issues
60 =head1 AUTHOR - Jason Stajich
62 Email jason-at-bioperl.org
66 The rest of the documentation details each of the object methods.
67 Internal methods are usually preceded with a _
72 # Let the code begin...
75 package Bio
::Matrix
::MatrixI
;
79 use base
qw(Bio::Root::RootI);
85 Usage : my $id = $matrix->matrix_id
86 Function: Get the matrix ID
87 Returns : string value
95 $self->throw_not_implemented();
101 Usage : my $name = $matrix->matrix_name();
102 Function: Get the matrix name
103 Returns : string value
112 $self->throw_not_implemented();
118 Usage : my $entry = $matrix->get_entry($rowname,$columname)
119 Function: Get the entry for a given row,column pair
130 $self->throw_not_implemented();
137 Usage : my @row = $matrix->get_column('ALPHA');
138 Function: Get a particular column
139 Returns : Array (in array context) or arrayref (in scalar context)
141 Args : name of the column
148 $self->throw_not_implemented();
154 Usage : my @row = $matrix->get_row('ALPHA');
155 Function: Get a particular row
156 Returns : Array (in array context) or arrayref (in scalar context)
158 Args : name of the row
164 $self->throw_not_implemented();
171 Usage : my @diagonal = $matrix->get_diagonal;
172 Function: Get the diagonal of the matrix
173 Returns : Array (in array context) or arrayref (in scalar context)
181 $self->throw_not_implemented();
184 =head2 column_num_for_name
186 Title : column_num_for_name
187 Usage : my $num = $matrix->column_num_for_name($name)
188 Function: Gets the column number for a particular column name
195 sub column_num_for_name
{
198 $self->throw_not_implemented();
201 =head2 row_num_for_name
203 Title : row_num_for_name
204 Usage : my $num = $matrix->row_num_for_name($name)
205 Function: Gets the row number for a particular row name
212 sub row_num_for_name
{
214 $self->throw_not_implemented();
220 Usage : my $rowcount = $matrix->num_rows;
221 Function: Get the number of rows
230 $self->throw_not_implemented();
237 Usage : my $colcount = $matrix->num_columns
238 Function: Get the number of columns
247 $self->throw_not_implemented();
255 Usage : my $matrix = $matrix->reverse
256 Function: Get the reverse of a matrix
265 $self->throw_not_implemented();
271 Usage : my @rows = $matrix->row_names
272 Function: The names of all the rows
273 Returns : array in array context, arrayref in scalar context
281 $self->throw_not_implemented();
288 Usage : my @columns = $matrix->column_names
289 Function: The names of all the columns
290 Returns : array in array context, arrayref in scalar context
298 $self->throw_not_implemented();