GenOO::RegionCollection::Type::DBIC - Class for a collection of GenOO::Region objects stored in a database.
# Object that corresponds to a collection of GenOO::Region objects. # To initialize my $region_collection = GenOO::RegionCollection::DB->new( driver => undef, host => undef, database => undef, table => undef, user => undef, password => undef, port => undef, name => undef, species => undef, description => undef, extra => undef, );
This class consumes the L<GenOO::RegionCollection> role. An instance of this class corresponds to a collection of records consuming the L<GenOO::Region> role.The records are stored in a database (ie MySQL, SQLite, etc) and the class offers methods for quering them and accessing specific characteristics (eg. longest record). Internally the class rests on DBIx::Class for the database access and for defining the appropriate result objects. Note that the columns which correspond to the required attributes of L<GenOO::Region> must exist in the table schema (ie. strand, rname, start, stop, copy_number)
# Get the records contained in a specific region my @records = $region_collection->records_contained_in_region(1,'chr3',127726308,127792250); # Get the longest record my $longest_record = $region_collection->longest_record;
To install GenOO, copy and paste the appropriate command in to your terminal.
cpanm
cpanm GenOO
CPAN shell
perl -MCPAN -e shell install GenOO
For more information on module installation, please visit the detailed CPAN module installation guide.