[Bioperl-l] dnastatistics
Jason Stajich
jason at bioperl.org
Tue Sep 22 16:01:51 UTC 2009
someone should pick up the ball.
On Sep 22, 2009, at 4:12 AM, Mark A. Jensen wrote:
> Thanks Liam-- I think the discrepancy between dnadist and the
> module is worth making a bug report for- can you do that and
> include the data (or part of it) you were using?
> Jason, is that work really underway, or should someone pick up
> that ball?
> ----- Original Message ----- From: "Liam Elbourne" <lelbourn at science.mq.edu.au
> >
> To: "Jason Stajich" <jason at bioperl.org>
> Cc: "Mark A. Jensen" <maj at fortinbras.us>; <bioperl-l at bioperl.org>;
> "Jose ." <joseguillin at hotmail.com>
> Sent: Tuesday, September 22, 2009 3:14 AM
> Subject: [Bioperl-l] dnastatistics
>
>
> So I also had no problem running the code as written by Jose (Bioperl
> 1.6.0, perl 5.10), but in the documentation for DNAStatistics it says:
>
> "The routines are not well tested and do contain errors at this point.
> Work is underway to correct them, but do not expect this code to give
> you the right answer currently!"!
>
> So I'm using dnadist (as I think the documentation recommends), and it
> does produce different numbers to $stats->distance(-).
>
> I tried write_matrix from Bio::Matrix::IO - got a message saying it
> hasn't been implemented yet?
>
> And if Jose hasn't already found it, try Data::Dumper; it will change
> your life....
>
> Regards,
> Liam.
>
> On 15/09/2009, at 3:54 AM, Jason Stajich wrote:
>
>> Yeah it seems like more of a bioperl problem -- possible that the
>> older code didn't recognize 'jukes-cantor' but you can try the
>> abbreviation 'jc' -- better to just upgrade tho!
>>
>> This isn't the cause of the problem but I would also encourage use
>> of Bio::Matrix::IO for printing the matrix (use the 'write_matrix'
>> function) rather than print_matrix on the matrix itsself.
>>
>> -jason
>> On Sep 14, 2009, at 10:00 AM, Mark A. Jensen wrote:
>>
>>> Hi Jose--
>>> I don't get any problem with your script as written. You should
>>> upgrade to
>>> BioPerl 1.6 and try again.
>>> The "unblessed reference" is $jcmatrix. It may be undef for some
>>> reason.
>>> MAJ
>>> ----- Original Message ----- From: "Jose ."
>>> <joseguillin at hotmail.com>
>>> To: <bioperl-l at bioperl.org>
>>> Sent: Monday, September 14, 2009 8:48 AM
>>> Subject: [Bioperl-l] Bio/Align/DNAStatistics.html print$jcmatrix-
>>> >print_matrix;
>>>
>>>
>>>
>>>
>>>
>>> Hello,
>>>
>>> I'm trying to use Bio::Align::DNAStatistics, but I get the
>>> following message:
>>>
>>> Can't call method "print_matrix" on unblessed reference at
>>> Tree.pl line 32, <GEN0> line 44.
>>>
>>> Other modules do work, such us Bio::SimpleAlign;
>>>
>>>
>>>
>>>
>>> My code is basically a modification of the code I found in http://doc.bioperl.org/releases/bioperl-current/bioperl-live/Bio/Align/DNAStatistics.html
>>> , as it is as follows:
>>>
>>> use strict;
>>> use Bio::AlignIO;
>>> use Bio::Align::DNAStatistics;
>>>
>>>
>>> my $stats = Bio::Align::DNAStatistics->new();
>>>
>>> my $alignin = Bio::AlignIO->new(-file => 'e1_output_uno_solo.fas',
>>> -format => 'fasta');
>>> my $aln = $alignin->next_aln;
>>>
>>> my $jcmatrix = $stats-> distance (-align => $aln,
>>> -method => 'Jukes-Cantor');
>>>
>>> print $jcmatrix->print_matrix;
>>>
>>> And the file 'e1_output_uno_solo.fas' has the following sequences:
>>>
>>>> A
>>> GGTTATCTCAACAACTGTCACC--GTGGGCGCTGGTCATTGGTACGGGTGAACGAGAGTT
>>> AAACGGTCGTTAACCATAGAAACAAAACACACTGCACCTTAACTCACTGAATAGTTGACG
>>> GTCTGCCTCAGGGCTTGAGACAACGGATGGATCTAAACTCATGCTGTAGCCTATCAAACT
>>> TAGCCCCAGGGTACTTCCGTCCCTAGCCTCGCTACAAGGCCAGAAAGGGTTTTGAAGTCT
>>> ACTCACTGTGACCAGCGGTCTAGTCAGGTTATGCTTCGGCACAAAACCTCAGAATCGGTA
>>> ACCAGCCACTACACGAACTGAAATCAAATCGCGGGAGGTGGTCCATCTTTGTCCACGCTG
>>> CGATGATTGGGTTGCTTTATAGTCTAGCTGCAAGGTTTTGCGTTCTGGTGGGAAGCGGSubject
>>> : Re: [Bioperl-l] Bio/Align/DNAStatistics.html
>> print$jcmatrix->print_maCA
>>> TCCAAGGGGTTGACTCCGCTCGTTTATAACATGCCTTGGGCCTCCATGGTGAGTCGCAAC
>>> GTCAGCGTAGGCCTAGACGGCT
>>>
>>>> B
>>> GGATATCTCGACAACTTTTAGC--CTGGGCGCTTGGCATTGGTACACGTGACTTGCAGTT
>>> AAAGGGTCGTTATACATAGAATCACTACCCAC--CAGGCGAACTCGCTGGAGAGCTGAGG
>>> GTCACCCTCAGCGGTTGAGTTAACTGCTCGATGTTAACCGATGTTGGATCATAGGTAACT
>>> TATCCTCAGTGTTCCTCTGTCCCTAGACTGGCTACAGGGCTACACCGGGTTTGAGGGGAT
>>> ACTGACTGTTTTCAGCGGTAGTGTAAGTGTATGGTCCAACCCAAGGGTTCATGACCGGTA
>>> AACTGCCCGTTCCCGCATTGAAATCAAATTGCAGGAGTTGGTACTTATTTGTCAACCTTA
>>> CGATGATTGGGATGCATTTTAGTCGGGCTGGGCGGATTTGCGATCTGGGTGGAAGAGAGA
>>> TGCATGGGGCTAACTCGTCTTGGTGAGTACCGGCATTGCACCGCAATGGACCGCCAAAAC
>>> ATAAGAGTAGGTCGGGATGGCA
>>>
>>>> C
>>> GCTTATCTCAACAACCGACACGAAGTCGTCGCAGGTCAATGGTACACGTGAATTGAAGTC
>>> ATAAGATCAGTAATGATCGAACCACCAAACCCTTAACCTCGACTCACGCGATAGCCGAGG
>>> GTCTGCCTCCAGGGTTGATTTAAAGGTTCTATTTAAGACCGTTTTCGATCATAGGTTACT
>>> TATCCCCAGAGTTCTACCGTCGTGAGAATGGCTACAAGGCTAGAATAGGTTTTAGGGT-T
>>> ACTTACGGTCTGCAGCCGTATTGTGAGGTTATGGTCCGGCCCTAGGCGTCATGACCGATA
>>> ATCAGCCCCTACCTGAAATGAAATCAAATCGCGGGAGTTGGTACTTATCTGTCAACGTTG
>>> CGATGATGGGGATACATGTTGGTCTACCGCGACGGACTAGCGATCACGGGGGAAGCGGAT
>>> TGCCCGGTGGTGACTCGACACGTTTAAAACCTGCCTGGTTCCCGCATGGATCGTCACAAC
>>> GTATGTGCAGGTCGAAACGAGT
>>>
>>>> D
>>> CGTGATCGCAACAACTGTCACC--GTGGGCGCTGGCCGTTGGACCACGTGAAATGCTGTT
>>> AAACGATCGTTCACCATAGAACCACTACACTCTTCACCTCAACCCGCGGGACAGGTGATG
>>> GTGTCCCCCAGGGGTTGAGTGAACGGCTCGATGTAAACCCATGTTCGATCATAGGTAACG
>>> TAGCCCCAGGGTGATTCCGTTCCTAAACTGGTTACAAGGCTAAAACGTGTTTTAGAGTAT
>>> AATGACTGTCTACGGCGGTATTGTGATGTTATCATCCGTCCCTAGGCGTGGCGACCGTTA
>>> AACAGCCTCTTCCCTAACTGATATCTAATCGTAGGAGTTGCTACGCATTTGTCAACGCAG
>>> CGATGATGGTGATGCATCTTAATCTAGCTGG----TTTTTTGATCTCGGGTGACGCAGAT
>>> AGTCAGGGGTTGACTCGCGTCGTTTGAAACGTGCCTTGCTCCTCAATGGACCCTCCGAAC
>>> CTAAGAGTAGCTCGACACGGCT
>>>
>>>
>>>
>>> I think the $aln object is OK, as I can use it with SimpleAlign.
>>>
>>> Moreover, if I write
>>> print $jcmatrix;
>>> instead of
>>> print $jcmatrix->print_matrix;
>>> I get the memory reference, as normal===> ARRAY(0x859f08)
>>>
>>> So my question is:
>>>
>>> Why do I have an unblessed reference?
>>>
>>> Can't call method "print_matrix" on unblessed reference at
>>> Tree.pl line 32, <GEN0> line 44.
>>>
>>> Thank you very much in advance.
>>>
>>> Jose G.
>>>
>>> _________________________________________________________________
>>> Hay tantos ordenadores como personas. ¡Descubre ahora cuál eres tú!
>>> http://www.quepceres.com/
>>> _______________________________________________
>>> Bioperl-l mailing list
>>> Bioperl-l at lists.open-bio.org
>>> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>>>
>>>
>>> _______________________________________________
>>> Bioperl-l mailing list
>>> Bioperl-l at lists.open-bio.org
>>> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>>
>> --
>> Jason Stajich
>> jason.stajich at gmail.com
>> jason at bioperl.org
>>
>>
>> _______________________________________________
>> Bioperl-l mailing list
>> Bioperl-l at lists.open-bio.org
>> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>
> ______________________________
>
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>
>
--
Jason Stajich
jason.stajich at gmail.com
jason at bioperl.org
More information about the Bioperl-l
mailing list