.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Bio::CodonUsage::Table 3pm" .TH Bio::CodonUsage::Table 3pm "2021-08-15" "perl v5.32.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Bio::CodonUsage::Table \- for access to the Codon usage Database at http://www.kazusa.or.jp/codon. .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 4 \& use Bio::CodonUsage::Table; \& use Bio::DB::CUTG; \& use Bio::CodonUsage::IO; \& use Bio::Tools::SeqStats; \& \& # Get a codon usage table from web database \& my $cdtable = Bio::DB::CUTG\->new(\-sp => \*(AqMus musculus\*(Aq, \& \-gc => 1); \& \& # Or from local file \& my $io = Bio::CodonUsage::IO\->new(\-file => "file"); \& my $cdtable = $io\->next_data(); \& \& # Or create your own from a Bio::PrimarySeq compliant object, \& # $codonstats is a ref to a hash of codon name /count key\-value pairs \& my $codonstats = Bio::Tools::SeqStats\->count_codons($Seq_objct); \& \& # \*(Aq\-data\*(Aq must be specified, \*(Aq\-species\*(Aq and \*(Aqgenetic_code\*(Aq are optional \& my $CUT = Bio::CodonUsage::Table\->new(\-data => $codonstats, \& \-species => \*(AqHsapiens_kinase\*(Aq); \& \& print "leu frequency is ", $cdtable\->aa_frequency(\*(AqLEU\*(Aq), "\en"; \& print "freq of ATG is ", $cdtable\->codon_rel_frequency(\*(Aqttc\*(Aq), "\en"; \& print "abs freq of ATG is ", $cdtable\->codon_abs_frequency(\*(AqATG\*(Aq), "\en"; \& print "number of ATG codons is ", $cdtable\->codon_count(\*(AqATG\*(Aq), "\en"; \& print "GC content at position 1 is ", $cdtable\->get_coding_gc(\*(Aq1\*(Aq), "\en"; \& print "total CDSs for Mus musculus is ", $cdtable\->cds_count(), "\en"; .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" This class provides methods for accessing codon usage table data. .PP All of the methods at present are simple look-ups of the table or are derived from simple calculations from the table. Future methods could include measuring the codon usage of a sequence , for example, or provide methods for examining codon usage in alignments. .SH "SEE ALSO" .IX Header "SEE ALSO" Bio::Tools::CodonTable, Bio::WebAgent, Bio::CodonUsage::IO, Bio::DB::CUTG .SH "FEEDBACK" .IX Header "FEEDBACK" .SS "Mailing Lists" .IX Subsection "Mailing Lists" User feedback is an integral part of the evolution of this and other Bioperl modules. Send your comments and suggestions preferably to one of the Bioperl mailing lists. Your participation is much appreciated. .PP .Vb 2 \& bioperl\-l@bioperl.org \- General discussion \& http://bioperl.org/wiki/Mailing_lists \- About the mailing lists .Ve .SS "Support" .IX Subsection "Support" Please direct usage questions or support issues to the mailing list: .PP \&\fIbioperl\-l@bioperl.org\fR .PP rather than to the module maintainer directly. Many experienced and reponsive experts will be able look at the problem and quickly address it. Please include a thorough description of the problem with code and data examples if at all possible. .SS "Reporting Bugs" .IX Subsection "Reporting Bugs" Report bugs to the Bioperl bug tracking system to help us keep track the bugs and their resolution. Bug reports can be submitted via the web: .PP .Vb 1 \& https://github.com/bioperl/bioperl\-live/issues .Ve .SH "AUTHORS" .IX Header "AUTHORS" Richard Adams, Richard.Adams@ed.ac.uk .SH "APPENDIX" .IX Header "APPENDIX" The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _ .SS "new" .IX Subsection "new" .Vb 10 \& Title : new \& Usage : my $cut = Bio::CodonUsage::Table\->new(\-data => $cut_hash_ref, \& \-species => \*(AqH.sapiens_kinase\*(Aq \& \-genetic_code =>1); \& Returns : a reference to a new Bio::CodonUsage::Table object \& Args : none or a reference to a hash of codon counts. This constructor is \& designed to be compatible with the output of \& Bio::Tools::SeqUtils::count_codons() \& Species and genetic code parameters can be entered here or via the \& species() and genetic_code() methods separately. .Ve .SS "all_aa_frequencies" .IX Subsection "all_aa_frequencies" .Vb 6 \& Title : all_aa_frequencies \& Usage : my $freq = $cdtable\->all_aa_frequencies(); \& Returns : a reference to a hash where each key is an amino acid \& and each value is its frequency in all proteins in that \& species. \& Args : none .Ve .SS "codon_abs_frequency" .IX Subsection "codon_abs_frequency" .Vb 6 \& Title : codon_abs_frequency \& Usage : my $freq = $cdtable\->codon_abs_frequency(\*(AqCTG\*(Aq); \& Purpose : To return the frequency of that codon as a percentage \& of all codons in the organism. \& Returns : a percentage frequency \& Args : a non\-ambiguous codon string .Ve .SS "codon_rel_frequency" .IX Subsection "codon_rel_frequency" .Vb 7 \& Title : codon_rel_frequency \& Usage : my $freq = $cdtable\->codon_rel_frequency(\*(AqCTG\*(Aq); \& Purpose : To return the frequency of that codon as a percentage \& of codons coding for the same amino acid. E.g., ATG and TGG \& would return 100 as those codons are unique. \& Returns : a percentage frequency \& Args : a non\-ambiguous codon string .Ve .SS "probable_codons" .IX Subsection "probable_codons" .Vb 8 \& Title : probable_codons \& Usage : my $prob_codons = $cd_table\->probable_codons(10); \& Purpose : to obtain a list of codons for the amino acid above a given \& threshold % relative frequency \& Returns : A reference to a hash where keys are 1 letter amino acid codes \& and values are references to arrays of codons whose frequency \& is above the threshold. \& Arguments: a minimum threshold frequency .Ve .SS "most_common_codons" .IX Subsection "most_common_codons" .Vb 6 \& Title : most_common_codons \& Usage : my $common_codons = $cd_table\->most_common_codons(); \& Purpose : To obtain the most common codon for a given amino acid \& Returns : A reference to a hash where keys are 1 letter amino acid codes \& and the values are the single most common codons for those amino acids \& Arguments: None .Ve .SS "codon_count" .IX Subsection "codon_count" .Vb 6 \& Title : codon_count \& Usage : my $count = $cdtable\->codon_count(\*(AqCTG\*(Aq); \& Purpose : To obtain the absolute number of the codons in the \& organism. \& Returns : an integer \& Args : a non\-ambiguous codon string .Ve .SS "get_coding_gc" .IX Subsection "get_coding_gc" .Vb 7 \& Title : get_coding_gc \& Usage : my $count = $cdtable\->get_coding_gc(1); \& Purpose : To return the percentage GC composition for the organism at \& codon positions 1,2 or 3, or an average for all coding sequence \& (\*(Aqall\*(Aq). \& Returns : a number (%\-age GC content) or 0 if these fields are undefined \& Args : 1,2,3 or \*(Aqall\*(Aq. .Ve .SS "set_coding_gc" .IX Subsection "set_coding_gc" .Vb 8 \& Title : set_coding_gc \& Usage : my $count = $cdtable\->set_coding_gc(\-1=>55.78); \& Purpose : To set the percentage GC composition for the organism at \& codon positions 1,2 or 3, or an average for all coding sequence \& (\*(Aqall\*(Aq). \& Returns : void \& Args : a hash where the key must be 1,2,3 or \*(Aqall\*(Aq and the value the %age GC \& at that codon position.. .Ve .SS "species" .IX Subsection "species" .Vb 5 \& Title : species \& Usage : my $sp = $cut\->species(); \& Purpose : Get/setter for species name of codon table \& Returns : Void or species name string \& Args : None or species name string .Ve .SS "genetic_code" .IX Subsection "genetic_code" .Vb 5 \& Title : genetic_code \& Usage : my $sp = $cut\->genetic_code(); \& Purpose : Get/setter for genetic_code name of codon table \& Returns : Void or genetic_code id, 1 by default \& Args : None or genetic_code id, 1 by default if invalid argument. .Ve .SS "cds_count" .IX Subsection "cds_count" .Vb 6 \& Title : cds_count \& Usage : my $count = $cdtable\->cds_count(); \& Purpose : To retrieve the total number of CDSs used to generate the Codon Table \& for that organism. \& Returns : an integer \& Args : none (if retrieving the value) or an integer( if setting ). .Ve .SS "aa_frequency" .IX Subsection "aa_frequency" .Vb 5 \& Title : aa_frequency \& Usage : my $freq = $cdtable\->aa_frequency(\*(AqLeu\*(Aq); \& Purpose : To retrieve the frequency of an amino acid in the organism \& Returns : a percentage \& Args : a 1 letter or 3 letter string representing the amino acid .Ve .SS "common_codon" .IX Subsection "common_codon" .Vb 5 \& Title : common_codon \& Usage : my $freq = $cdtable\->common_codon(\*(AqLeu\*(Aq); \& Purpose : To retrieve the frequency of the most common codon of that aa \& Returns : a percentage \& Args : a 1 letter or 3 letter string representing the amino acid .Ve .SS "rare_codon" .IX Subsection "rare_codon" .Vb 5 \& Title : rare_codon \& Usage : my $freq = $cdtable\->rare_codon(\*(AqLeu\*(Aq); \& Purpose : To retrieve the frequency of the least common codon of that aa \& Returns : a percentage \& Args : a 1 letter or 3 letter string representing the amino acid .Ve