[Bioperl-l] PAML::Codeml

SunXinli xinlisun at hotmail.com
Thu Apr 21 05:28:12 UTC 2011





	
	
	
	

Dear Sir or Madam,




I met a problem when run
Bio::Tools::Run::Phylo::PAML::Codeml to calculate Ka/Ks ratio of 
pairwise sequences. However, the result is fine when I use the same DNA sequence file to run
Bio::Tools::Run::Phylo::PAML::Yn00.


bioperl version is 1.61-1, and
PAML version is 4.4.

#!/usr/bin/perl -w


  use
Bio::Tools::Run::Phylo::PAML::Codeml;

  use Bio::AlignIO;


  my $alignio =
Bio::AlignIO->new(-format => 'phylip',

                                 -file
  => 'out');


 while ( my $aln =
$alignio->next_aln){


  my $codeml =
Bio::Tools::Run::Phylo::PAML::Codeml->new(

			-params => { 'runmode' =>
-2,

                                     'seqtype'
=> 1,

                                }
);

	$codeml->alignment($aln);

  my ($rc,$parser) =
$codeml->run();


 while ( my $result =
$parser->next_result ){


  my $MLmatrix =
$result->get_MLmatrix();

  my $dN =
$MLmatrix->[0]->[1]->{dN};

  my $dS =
$MLmatrix->[0]->[1]->{dS};

  my $kaks
=$MLmatrix->[0]->[1]->{omega};

    print "Ka = $dN Ks = $dS
Ka/Ks = $kaks\n";

	}

}










Error message:
------------- EXCEPTION:
Bio::Root::NotImplemented -------------

MSG: Unknown format of PAML
output did not see seqtype

STACK: Error::throw

STACK: Bio::Root::Root::throw
/usr/share/perl5/Bio/Root/Root.pm:368

STACK:
Bio::Tools::Phylo::PAML::_parse_summary
/usr/share/perl5/Bio/Tools/Phylo/PAML.pm:461

STACK:
Bio::Tools::Phylo::PAML::next_result
/usr/share/perl5/Bio/Tools/Phylo/PAML.pm:270

STACK: Codeml.pl:18

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





Thanks a lot,




Xinli
 
 		 	   		  



More information about the Bioperl-l mailing list