2 # BioPerl module for Bio::Assembly::ScaffoldI
4 # Copyright by Robson F. de Souza
6 # You may distribute this module under the same terms as perl itself
8 # POD documentation - main docs before the code
12 Bio::Assembly::ScaffoldI - Abstract Inteface of Sequence Assemblies
16 # get a Bio::Assembly::ScaffoldI object somehow
18 foreach my $contig ($assembly->all_contigs) {
19 # do something (see Bio::Assembly::Contig)
24 This interface defines the basic set of methods an object should have
25 to manipulate assembly data.
31 User feedback is an integral part of the evolution of this and other
32 Bioperl modules. Send your comments and suggestions preferably to the
33 Bioperl mailing lists Your participation is much appreciated.
35 bioperl-l@bioperl.org - General discussion
36 http://bioperl.org/wiki/Mailing_lists - About the mailing lists
40 Please direct usage questions or support issues to the mailing list:
42 I<bioperl-l@bioperl.org>
44 rather than to the module maintainer directly. Many experienced and
45 reponsive experts will be able look at the problem and quickly
46 address it. Please include a thorough description of the problem
47 with code and data examples if at all possible.
51 Report bugs to the Bioperl bug tracking system to help us keep track
52 the bugs and their resolution. Bug reports can be submitted via the
55 https://github.com/bioperl/bioperl-live/issues
57 =head1 AUTHOR - Robson Francisco de Souza
59 Email: rfsouza@citri.iq.usp.br
63 The rest of the documentation details each of the object
64 methods. Internal methods are usually preceded with a _
72 package Bio
::Assembly
::ScaffoldI
;
79 use base
qw(Bio::Root::RootI);
84 =head1 Accessing general assembly data
88 =head2 get_nof_contigs
90 Title : get_nof_contigs
91 Usage : $assembly->get_nof_contigs()
92 Function: Get the number of contigs included in the assembly
101 $self->throw_not_implemented();
104 =head2 get_nof_singlets
106 Title : get_nof_singlets
107 Usage : $assembly->get_nof_singlets()
108 Function: Get the number of singlets included in the assembly
114 sub get_nof_singlets
{
117 $self->throw_not_implemented();
120 =head2 get_contig_ids
122 Title : get_contig_ids
123 Usage : $assembly->get_contig_ids()
124 Function: Access list of contig IDs from assembly
125 Returns : an array if there are any contigs in the assembly.
127 Args : an array of contig IDs
134 $self->throw_not_implemented();
137 =head2 get_singlet_ids
139 Title : get_singlet_ids
140 Usage : $assembly->get_singlet_ids()
141 Function: Access list of singlet IDs from assembly
142 Returns : an array if there are any singlets in the assembly.
144 Args : an array of singlet IDs
148 sub get_singlet_ids
{
151 $self->throw_not_implemented();
154 =head2 get_contig_by_id
156 Title : get_contig_by_id
157 Usage : $assembly->get_contig_by_id($id)
158 Function: Get a reference for a contig from the assembly
159 Returns : a Bio::Assembly::Contig object or undef
160 Args : [string] contig unique identifier (ID)
164 sub get_contig_by_id
{
166 $self->throw_not_implemented();
169 =head2 get_singlet_by_id
171 Title : get_singlet_by_id
172 Usage : $assembly->get_singlet_by_id()
173 Function: Get a reference for a singlet from the assembly
174 Returns : Bio::Assembly::Singlet object or undef
175 Args : [string] a singlet ID
179 sub get_singlet_by_id
{
181 $self->throw_not_implemented();
184 =head1 Modifier methods
186 Implementation of these methods is optional in the sense that
187 read-only implementations may not have these. If an object implements
188 one of them, it should however implement all.
195 Usage : $assembly->add_contig($contig)
196 Function: Add another contig to the Bio::Assembly::ScaffoldI object
197 Returns : 1 on success, 0 otherwise
198 Args : a Bio::Assembly:Contig object
200 See Bio::Assembly::Contig for more information
204 #---------------------
206 #---------------------
208 $self->throw_not_implemented();
214 Usage : $assembly->add_singlet($seq)
215 Function: Add another singlet to the Bio::Assembly::ScaffoldI object
216 Returns : 1 on success, 0 otherwise
217 Args : a Bio::Assembly::Singlet object
221 #---------------------
223 #---------------------
225 $self->throw_not_implemented();
228 =head2 remove_contigs
230 Title : remove_contigs
231 Usage : $assembly->remove_contigs(1..4)
232 Function: Remove contig from assembly object
233 Returns : a Bio::Assembly::Contig object
234 Args : a list of contig IDs
236 See function get_contig_ids() above
240 #---------------------
242 #---------------------
244 $self->throw_not_implemented();
247 =head2 remove_singlets
249 Title : remove_singlets
250 Usage : $assembly->remove_singlets(1..4)
251 Function: Remove singlets from assembly object
252 Returns : an array of Bio::Assembly::Singlet objects
253 Args : an array of singlet IDs
255 See function get_singlet_ids() above
259 #---------------------
260 sub remove_singlets
{
261 #---------------------
263 $self->throw_not_implemented();
266 =head1 Contig and singlet selection methos
270 =head2 select_contigs
272 Title : select_contig
273 Usage : $assembly->select_contig
274 Function: Selects an array of contigs from the assembly
275 Returns : an array of Bio::Assembly::Contig objects
276 Args : an array of contig ids
278 See function get_contig_ids() above
282 #---------------------
284 #---------------------
286 $self->throw_not_implemented();
289 =head2 select_singlets
291 Title : select_singlets
292 Usage : $assembly->select_singlets(@list)
293 Function: Selects an array of singlets from the assembly
294 Returns : an array of Bio::Assembly::Singlet objects
295 Args : an array of singlet ids
297 See function get_singlet_ids() above
301 #---------------------
302 sub select_singlets
{
303 #---------------------
305 $self->throw_not_implemented();
311 Usage : my @contigs = $assembly->all_contigs
312 Function: Returns a list of all contigs in this assembly.
313 Contigs are both clusters and alignments of one
314 or more reads, with an associated consensus
316 Returns : array of Bio::Assembly::Contig
321 #---------------------
323 #---------------------
325 $self->throw_not_implemented();
331 Usage : my @singlets = $assembly->all_singlets
332 Function: Returns a list of all singlets in this assembly.
333 Singlets are isolated reads, without non-vector
334 matches to any other read in the assembly.
335 Returns : array of Bio::Assembly::Singlet objects
340 #---------------------
342 #---------------------
344 $self->throw_not_implemented();