[Bioperl-l] position method in Bio::Restriction::Analysis

Mark Nadel nadel at nabsys.com
Thu Jul 7 17:04:37 EDT 2011


I am having trouble using the position method, and no sample code is
included in the documentation.

Here is my script:
*
*
*

use strict;

use Bio::Restriction::EnzymeCollection;

use Bio::Restriction::Analysis;

use Bio::DB::GenBank;

use Bio::Seq;

use Bio::SeqIO;

use Bio::Seq::RichSeq;

use Bio::Tools::SeqStats;



my $accension_number = 'M77815';  ##'U00096.2';


my $outputFile = "/Users/marknadel/Documents/UniqueCutters".$
accension_number.".txt";


open OUT, ">$outputFile" or die "Can't open $outputFile";


my $db = Bio::DB::GenBank->new();


my $seq = $db->get_Seq_by_acc($accension_number);


print ">";

print $seq->desc();

print "\tThe sequence is circular:";

print $seq->is_circular();



print "\n";


my $ra = Bio::Restriction::Analysis->new(-seq=>$seq);


my $all_cutters = $ra->cutters;


my $uniqe = $ra->unique_cutters;





foreach my $enz ($uniqe->each_enzyme()){

print $enz->name();

print OUT $enz->name();

print "\t";

print OUT "\t";

    my @cutpoint = $enz->position();

    #print $cutpoint;

   # print OUT $cutpoint;





   }

print "\n";

    print OUT "\n";

    close OUT;

---------------------


and here is the output:


>M13mp18 phage cloning vector. The sequence is circular:1

AasI Can't locate object method "position" via package
"Bio::Restriction::Enzyme"
at /Users/marknadel/Documents/workspace/adHoc/unique_cutters.pl line 42,
<DATA> line 532.


I had a similar problem before with another method  in this package and
someone was kind enough to give me the exact syntax.

Thanks in advance,

Mark

*

-- 
*Mark Nadel*
*Principal Scientist
*
NABsys Inc.
60 Clifford Street
Providence, RI  02903

Phone   401-276-9100 x204
Fax 401-276-9122



More information about the Bioperl-l mailing list