~ubuntu-branches/ubuntu/wily/bioperl-run/wily-proposed

« back to all changes in this revision

Viewing changes to Bio/Tools/Run/PiseApplication/map.pm

  • Committer: Bazaar Package Importer
  • Author(s): Charles Plessy
  • Date: 2009-09-03 11:00:03 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090903110003-11of27rxner5vnl9
Tags: 1.6.1-1
* New upstream release.
* debian/patches/10-wrong-path-for-interpreter.patch: removed
  (fixed upstream).
* debian/watch updated (bioperl -> BioPerl).
* debian/rules refreshed with dh-make-perl 0.53.
  - Disabled installation of examples (removed upstream).
  - Removed the correction of file permission of Pise documentation
    (removed upstream).
  - Removed patching facilities (no patches anymore).
  - Disabled tests as I experience failures with t/Eponine.t despite
    this program is not installed.
* debian/copyright:
  - Removed vanity lines about debianization and debian copyright.
  - Incremented years to 2009.
  - Updated to latest experimentation of the machine-readable license summary.
* debian/control:
  - Incremented Standards-Version to reflect conformance on new Policy
    (dropped versionned build-dependancy on Perl).
  - Removed build-dependancy on quilt (no patches anymore).
  - Depend and Build-Depend on bioperl versions superior or equal to 1.6.0.
  - Build-depends on, and Recommdnes libalgorithm-diff-perl, libipc-run-perl,
    libio-string-perl and libxml-twig-perl, that are listed in DEPENDANCIES.
  - Build-depends on libarray-compare-perl and libtree-dagnode-perl
    (otherwise tests fail). 
  - Depend on amap-align instead of amap (Closes: #541274).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# $Id: map.pm,v 1.6 2006/07/04 22:23:34 mauricio Exp $
2
 
# BioPerl module for Bio::Tools::Run::PiseApplication::map
3
 
#
4
 
# Cared for by Catherine Letondal <letondal@pasteur.fr>
5
 
#
6
 
# For copyright and disclaimer see below.
7
 
#
8
 
# POD documentation - main docs before the code
9
 
 
10
 
=head1 NAME
11
 
 
12
 
Bio::Tools::Run::PiseApplication::map
13
 
 
14
 
=head1 SYNOPSIS
15
 
 
16
 
  #
17
 
 
18
 
=head1 DESCRIPTION
19
 
 
20
 
Bio::Tools::Run::PiseApplication::map
21
 
 
22
 
      Bioperl class for:
23
 
 
24
 
        MAP     Multiple Alignment Program
25
 
 
26
 
 
27
 
      Parameters: 
28
 
 
29
 
        (see also:
30
 
          http://bioweb.pasteur.fr/seqanal/interfaces/map.html 
31
 
         for available values):
32
 
 
33
 
 
34
 
                map (String)
35
 
 
36
 
                seq (Sequence)
37
 
                        Sequences File
38
 
 
39
 
                gap_size (Integer)
40
 
                        gap size: minimum length of any gap in a short sequence charged with a constant gap penalty (gs)
41
 
 
42
 
                mismatch (Integer)
43
 
                        score of a mismatch (<0)
44
 
 
45
 
                gapopen (Integer)
46
 
                        gap open penalty (>=0)
47
 
 
48
 
                gapext (Integer)
49
 
                        gap extension penalty (>=0)
50
 
 
51
 
                matrix (InFile)
52
 
                        Matrix (Name of a file containing an alternate or user-defined scoring matrix)
53
 
 
54
 
=head1 FEEDBACK
55
 
 
56
 
=head2 Mailing Lists
57
 
 
58
 
User feedback is an integral part of the evolution of this and other
59
 
Bioperl modules. Send your comments and suggestions preferably to
60
 
the Bioperl mailing list.  Your participation is much appreciated.
61
 
 
62
 
  bioperl-l@bioperl.org                  - General discussion
63
 
  http://bioperl.org/wiki/Mailing_lists  - About the mailing lists
64
 
 
65
 
=head2 Reporting Bugs
66
 
 
67
 
Report bugs to the Bioperl bug tracking system to help us keep track
68
 
of the bugs and their resolution. Bug reports can be submitted via the
69
 
web:
70
 
 
71
 
  http://bugzilla.open-bio.org/
72
 
 
73
 
=head1 AUTHOR
74
 
 
75
 
Catherine Letondal (letondal@pasteur.fr)
76
 
 
77
 
=head1 COPYRIGHT
78
 
 
79
 
Copyright (C) 2003 Institut Pasteur & Catherine Letondal.
80
 
All Rights Reserved.
81
 
 
82
 
This module is free software; you can redistribute it and/or modify
83
 
it under the same terms as Perl itself.
84
 
 
85
 
=head1 DISCLAIMER
86
 
 
87
 
This software is provided "as is" without warranty of any kind.
88
 
 
89
 
=head1 SEE ALSO
90
 
 
91
 
=over
92
 
 
93
 
=item *
94
 
 
95
 
http://bioweb.pasteur.fr/seqanal/interfaces/map.html
96
 
 
97
 
=item *
98
 
 
99
 
Bio::Tools::Run::PiseApplication
100
 
 
101
 
=item *
102
 
 
103
 
Bio::Tools::Run::AnalysisFactory::Pise
104
 
 
105
 
=item *
106
 
 
107
 
Bio::Tools::Run::PiseJob
108
 
 
109
 
=back
110
 
 
111
 
=cut
112
 
 
113
 
#'
114
 
package Bio::Tools::Run::PiseApplication::map;
115
 
 
116
 
use vars qw(@ISA);
117
 
use strict;
118
 
use Bio::Tools::Run::PiseApplication;
119
 
 
120
 
@ISA = qw(Bio::Tools::Run::PiseApplication);
121
 
 
122
 
=head2 new
123
 
 
124
 
 Title   : new()
125
 
 Usage   : my $map = Bio::Tools::Run::PiseApplication::map->new($location, $email, @params);
126
 
 Function: Creates a Bio::Tools::Run::PiseApplication::map object.
127
 
           This method should not be used directly, but rather by 
128
 
           a Bio::Tools::Run::AnalysisFactory::Pise instance.
129
 
           my $factory = Bio::Tools::Run::AnalysisFactory::Pise->new();
130
 
           my $map = $factory->program('map');
131
 
 Example : -
132
 
 Returns : An instance of Bio::Tools::Run::PiseApplication::map.
133
 
 
134
 
=cut
135
 
 
136
 
sub new {
137
 
    my ($class, $location, $email, @params) = @_;
138
 
    my $self = $class->SUPER::new($location, $email);
139
 
 
140
 
# -- begin of definitions extracted from /local/gensoft/lib/Pise/5.a/PerlDef/map.pm
141
 
 
142
 
    $self->{COMMAND}   = "map";
143
 
    $self->{VERSION}   = "5.a";
144
 
    $self->{TITLE}   = "MAP";
145
 
 
146
 
    $self->{DESCRIPTION}   = "Multiple Alignment Program";
147
 
 
148
 
    $self->{OPT_EMAIL}   = 0;
149
 
 
150
 
    $self->{_INTERFACE_STANDOUT} = undef;
151
 
    $self->{_STANDOUT_FILE} = undef;
152
 
 
153
 
    $self->{TOP_PARAMETERS}  = [ 
154
 
        "map",
155
 
        "seq",
156
 
        "scoring",
157
 
 
158
 
    ];
159
 
 
160
 
    $self->{PARAMETERS_ORDER}  = [
161
 
        "map",
162
 
        "seq",  # Sequences File
163
 
        "scoring",      # Scoring Parameters
164
 
        "gap_size",     # gap size: minimum length of any gap in a short sequence charged with a constant gap penalty (gs)
165
 
        "mismatch",     # score of a mismatch (<0)
166
 
        "gapopen",      # gap open penalty (>=0)
167
 
        "gapext",       # gap extension penalty (>=0)
168
 
        "matrix",       # Matrix (Name of a file containing an alternate or user-defined scoring matrix)
169
 
 
170
 
    ];
171
 
 
172
 
    $self->{TYPE}  = {
173
 
        "map" => 'String',
174
 
        "seq" => 'Sequence',
175
 
        "scoring" => 'Paragraph',
176
 
        "gap_size" => 'Integer',
177
 
        "mismatch" => 'Integer',
178
 
        "gapopen" => 'Integer',
179
 
        "gapext" => 'Integer',
180
 
        "matrix" => 'InFile',
181
 
 
182
 
    };
183
 
 
184
 
    $self->{FORMAT}  = {
185
 
        "map" => {
186
 
                "seqlab" => 'map',
187
 
                "perl" => '"map"',
188
 
        },
189
 
        "seq" => {
190
 
                "perl" => '" $value"',
191
 
        },
192
 
        "scoring" => {
193
 
        },
194
 
        "gap_size" => {
195
 
                "perl" => '(defined $value)? " $value" : ""',
196
 
        },
197
 
        "mismatch" => {
198
 
                "perl" => '($value < 0 && ! $matrix)? " $value" : "" ',
199
 
        },
200
 
        "gapopen" => {
201
 
                "perl" => '(defined $value)? " $value" : "" ',
202
 
        },
203
 
        "gapext" => {
204
 
                "perl" => '(defined $value)? " $value" : ""',
205
 
        },
206
 
        "matrix" => {
207
 
                "perl" => ' ($value)? " $value" : ""',
208
 
        },
209
 
 
210
 
    };
211
 
 
212
 
    $self->{FILENAMES}  = {
213
 
 
214
 
    };
215
 
 
216
 
    $self->{SEQFMT}  = {
217
 
 
218
 
    };
219
 
 
220
 
    $self->{GROUP}  = {
221
 
        "map" => 0,
222
 
        "seq" => 1,
223
 
        "gap_size" => 2,
224
 
        "mismatch" => 3,
225
 
        "gapopen" => 4,
226
 
        "gapext" => 5,
227
 
        "matrix" => 3,
228
 
 
229
 
    };
230
 
 
231
 
    $self->{BY_GROUP_PARAMETERS}  = [
232
 
        "map",
233
 
        "scoring",
234
 
        "seq",
235
 
        "gap_size",
236
 
        "mismatch",
237
 
        "matrix",
238
 
        "gapopen",
239
 
        "gapext",
240
 
 
241
 
    ];
242
 
 
243
 
    $self->{SIZE}  = {
244
 
 
245
 
    };
246
 
 
247
 
    $self->{ISHIDDEN}  = {
248
 
        "map" => 1,
249
 
        "seq" => 0,
250
 
        "scoring" => 0,
251
 
        "gap_size" => 0,
252
 
        "mismatch" => 0,
253
 
        "gapopen" => 0,
254
 
        "gapext" => 0,
255
 
        "matrix" => 0,
256
 
 
257
 
    };
258
 
 
259
 
    $self->{ISCOMMAND}  = {
260
 
        "map" => 1,
261
 
        "seq" => 0,
262
 
        "scoring" => 0,
263
 
        "gap_size" => 0,
264
 
        "mismatch" => 0,
265
 
        "gapopen" => 0,
266
 
        "gapext" => 0,
267
 
        "matrix" => 0,
268
 
 
269
 
    };
270
 
 
271
 
    $self->{ISMANDATORY}  = {
272
 
        "map" => 0,
273
 
        "seq" => 1,
274
 
        "scoring" => 0,
275
 
        "gap_size" => 1,
276
 
        "mismatch" => 1,
277
 
        "gapopen" => 1,
278
 
        "gapext" => 1,
279
 
        "matrix" => 0,
280
 
 
281
 
    };
282
 
 
283
 
    $self->{PROMPT}  = {
284
 
        "map" => "",
285
 
        "seq" => "Sequences File",
286
 
        "scoring" => "Scoring Parameters",
287
 
        "gap_size" => "gap size: minimum length of any gap in a short sequence charged with a constant gap penalty (gs)",
288
 
        "mismatch" => "score of a mismatch (<0)",
289
 
        "gapopen" => "gap open penalty (>=0)",
290
 
        "gapext" => "gap extension penalty (>=0)",
291
 
        "matrix" => "Matrix (Name of a file containing an alternate or user-defined scoring matrix)",
292
 
 
293
 
    };
294
 
 
295
 
    $self->{ISSTANDOUT}  = {
296
 
        "map" => 0,
297
 
        "seq" => 0,
298
 
        "scoring" => 0,
299
 
        "gap_size" => 0,
300
 
        "mismatch" => 0,
301
 
        "gapopen" => 0,
302
 
        "gapext" => 0,
303
 
        "matrix" => 0,
304
 
 
305
 
    };
306
 
 
307
 
    $self->{VLIST}  = {
308
 
 
309
 
        "scoring" => ['gap_size','mismatch','gapopen','gapext','matrix',],
310
 
    };
311
 
 
312
 
    $self->{FLIST}  = {
313
 
 
314
 
    };
315
 
 
316
 
    $self->{SEPARATOR}  = {
317
 
 
318
 
    };
319
 
 
320
 
    $self->{VDEF}  = {
321
 
 
322
 
    };
323
 
 
324
 
    $self->{PRECOND}  = {
325
 
        "map" => { "perl" => '1' },
326
 
        "seq" => { "perl" => '1' },
327
 
        "scoring" => { "perl" => '1' },
328
 
        "gap_size" => { "perl" => '1' },
329
 
        "mismatch" => { "perl" => '1' },
330
 
        "gapopen" => { "perl" => '1' },
331
 
        "gapext" => { "perl" => '1' },
332
 
        "matrix" => { "perl" => '1' },
333
 
 
334
 
    };
335
 
 
336
 
    $self->{CTRL}  = {
337
 
        "mismatch" => {
338
 
                "perl" => {
339
 
                        '($value >= 0)' => "enter a negative value",
340
 
                },
341
 
        },
342
 
        "gapopen" => {
343
 
                "perl" => {
344
 
                        '($value < 0)' => "enter a positive a null value",
345
 
                },
346
 
        },
347
 
        "gapext" => {
348
 
                "perl" => {
349
 
                        '($value < 0)' => "enter a positive a null value",
350
 
                },
351
 
        },
352
 
 
353
 
    };
354
 
 
355
 
    $self->{PIPEOUT}  = {
356
 
 
357
 
    };
358
 
 
359
 
    $self->{WITHPIPEOUT}  = {
360
 
 
361
 
    };
362
 
 
363
 
    $self->{PIPEIN}  = {
364
 
 
365
 
    };
366
 
 
367
 
    $self->{WITHPIPEIN}  = {
368
 
 
369
 
    };
370
 
 
371
 
    $self->{ISCLEAN}  = {
372
 
        "map" => 0,
373
 
        "seq" => 0,
374
 
        "scoring" => 0,
375
 
        "gap_size" => 0,
376
 
        "mismatch" => 0,
377
 
        "gapopen" => 0,
378
 
        "gapext" => 0,
379
 
        "matrix" => 0,
380
 
 
381
 
    };
382
 
 
383
 
    $self->{ISSIMPLE}  = {
384
 
        "map" => 1,
385
 
        "seq" => 1,
386
 
        "scoring" => 0,
387
 
        "gap_size" => 1,
388
 
        "mismatch" => 1,
389
 
        "gapopen" => 1,
390
 
        "gapext" => 1,
391
 
        "matrix" => 0,
392
 
 
393
 
    };
394
 
 
395
 
    $self->{PARAMFILE}  = {
396
 
 
397
 
    };
398
 
 
399
 
    $self->{COMMENT}  = {
400
 
        "scoring" => [
401
 
                "In the simplest form, users provide 3 integers: ms, q and r, where ms is the score of a mismatch and the score of an i-symbol indel is -(q + r * i). Each match automatically receives score 10. In addition, an integer gs is provided so that any gap of length > gs in a short sequence is given a penalty of -(q + r * gs), the linear penalty for a gap of length gs. In other words, long gaps in the short sequence are given a constant penalty. This simple scoring scheme may be used for DNA sequences. NOTE: all scores are integers.",
402
 
        ],
403
 
        "gap_size" => [
404
 
                "gapsize is provided so that any gap of length > gs in a short sequence is given a penalty of -(q + r * gs), the linear penalty for a gap of length gs. In other words, long gaps in the short sequence are given a constant penalty. ",
405
 
        ],
406
 
        "matrix" => [
407
 
                "users can define an alphabet of characters to appear in the sequences and a matrix that gives the substitution score for each pair of symbols in the alphabet. The 127 ASCII characters are eligible. The alphabet and matrix are given in a file, where the first line lists the characters in the alphabet and the lower triangle of the matrix comes next. ",
408
 
                "Example:",
409
 
                "ARNDC",
410
 
                " 13",
411
 
                "-15 19",
412
 
                "-10 -22 11",
413
 
                "-20 -10 -20 18",
414
 
                "-10 -20 -10 -20 12",
415
 
        ],
416
 
 
417
 
    };
418
 
 
419
 
    $self->{SCALEMIN}  = {
420
 
 
421
 
    };
422
 
 
423
 
    $self->{SCALEMAX}  = {
424
 
 
425
 
    };
426
 
 
427
 
    $self->{SCALEINC}  = {
428
 
 
429
 
    };
430
 
 
431
 
    $self->{INFO}  = {
432
 
 
433
 
    };
434
 
 
435
 
# -- end of definitions extracted from /local/gensoft/lib/Pise/5.a/PerlDef/map.pm
436
 
 
437
 
 
438
 
 
439
 
    $self->_init_params(@params);
440
 
 
441
 
    return $self;
442
 
}
443
 
 
444
 
 
445
 
 
446
 
1; # Needed to keep compiler happy
447