|
|||||||||
| Home >> All >> org >> xmlcml >> [ molutil overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.xmlcml.molutil
Class AminoAcid

java.lang.Objectorg.xmlcml.molutil.AminoAcid
- public class AminoAcid
- extends java.lang.Object
Provides the properties for a given aminoacid type; can retrieve these by 1- or 3(+)-letter codes; the latter has the capability of expanding to (say) HPRO, ORN, etc, whilst 1-letters are limited to one character. The term '3-letter' will refer to longer strings where necessary
Note that this class has (say) 20 instances and is effectively a provider of reference data and resettable properties such as colours.
| Field Summary | |
(package private) static HashedVector |
aa1Name
stores 1-letter AminoAcids, retrievable by 3-letters |
(package private) static HashedVector |
aa3Name
stores 3-letter AminoAcids, retrievable by 1-letters |
(package private) static java.util.Hashtable |
aaHashtable
the aminoAcids, hashed by three-letter and one-letter codes |
(package private) java.lang.String |
amino1
|
(package private) java.lang.String |
amino3
|
(package private) java.awt.Color |
color
|
(package private) static java.util.Hashtable |
fullNameTable
stores the fullname |
(package private) static double |
hmass
|
(package private) double |
hydrophobicity
|
(package private) static java.util.Hashtable |
indexTable
stores the index number (internal) |
(package private) double |
mwt
|
(package private) java.lang.String |
name
|
(package private) java.lang.String[] |
pdbNames
|
(package private) java.util.Hashtable |
realPropertyTable
|
(package private) java.lang.String |
smiles
|
| Constructor Summary | |
AminoAcid(java.lang.String a1,
java.lang.String a3,
java.lang.String nam,
java.lang.String sm,
java.lang.String[] pdb)
create from 1-letter, 3-letter, name, smiles, pdb atom names. |
|
| Method Summary | |
void |
debug()
|
static java.lang.String |
get1Letter(java.lang.String code)
return 1-letter code if valid 3-letter arg, else "?" |
static java.lang.String |
get1LetterSequence(java.lang.String[] s3)
get a gapless string of 1-letter codes from an array of 3-letter Strings |
static java.lang.String |
get3Letter(java.lang.String code)
if the arg is 1-letter, return the 3-letter, else return unchanged; unknown 1-letter returns "UNK" |
static java.lang.String[] |
get3LetterSequence(java.lang.String s1)
get an array of 3-letter Strings from a string of 1-letters; gaps are skipped |
static AminoAcid |
getAminoAcid(java.lang.String code)
get AminoAcid, hashed by one-letter or three-letter codes |
java.awt.Color |
getColor()
get the color of this AminoAcid |
static java.lang.String |
getFullName(java.lang.String code)
get fullname from code; returns null if not found |
double |
getHydrophobicity()
get hydrophobicity (Eisenberg, e.g. |
static double |
getMonomerMolWt(java.lang.String code)
get molecular weight of 'monomer': -N-CH(R)-C(=O)- (i.e. |
int |
getPAM250(AminoAcid a1,
AminoAcid a2)
returns score for a1 replacing a2 (from W.A.Pearson, Methods in Enzymology, (e.d R.Doolittle) ISBN 0-12-182084-X, Academic Press, San Diego, 183, (1990) 63-98 |
double |
getRealProperty(java.lang.String name)
get a real value already set with setRealProperty(); if name is not found, returns Double.NaN; |
static java.lang.String |
getSMILES(java.lang.String code)
get SMILES from code; returns null if not found |
static void |
main(java.lang.String[] args)
a test program on a nonsense sequence |
void |
setColor(java.awt.Color color)
set the color of this AminoAcid |
static void |
setColor(java.lang.String code,
java.awt.Color color)
sets the colour of an amino acid by its code |
void |
setRealProperty(java.lang.String name,
double value)
set a real value (double) for a given property, indexed by case-insensitive string. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
amino1
java.lang.String amino1
amino3
java.lang.String amino3
name
java.lang.String name
smiles
java.lang.String smiles
pdbNames
java.lang.String[] pdbNames
color
java.awt.Color color
realPropertyTable
java.util.Hashtable realPropertyTable
hydrophobicity
double hydrophobicity
mwt
double mwt
aa1Name
static HashedVector aa1Name
- stores 1-letter AminoAcids, retrievable by 3-letters
aa3Name
static HashedVector aa3Name
- stores 3-letter AminoAcids, retrievable by 1-letters
indexTable
static java.util.Hashtable indexTable
- stores the index number (internal)
fullNameTable
static java.util.Hashtable fullNameTable
- stores the fullname
aaHashtable
static java.util.Hashtable aaHashtable
- the aminoAcids, hashed by three-letter and one-letter codes
hmass
static double hmass
| Constructor Detail |
AminoAcid
public AminoAcid(java.lang.String a1, java.lang.String a3, java.lang.String nam, java.lang.String sm, java.lang.String[] pdb)
- create from 1-letter, 3-letter, name, smiles, pdb atom names. This is not
normally called except at static initialisation or if you discover a new AA.
| Method Detail |
setColor
public static void setColor(java.lang.String code, java.awt.Color color)
- sets the colour of an amino acid by its code
setColor
public void setColor(java.awt.Color color)
- set the color of this AminoAcid
getColor
public java.awt.Color getColor()
- get the color of this AminoAcid
getHydrophobicity
public double getHydrophobicity()
- get hydrophobicity (Eisenberg, e.g. Fasman p 637)
setRealProperty
public void setRealProperty(java.lang.String name, double value)
- set a real value (double) for a given property, indexed by
case-insensitive string. Example:
aa.setRealProperty("MYHYDROPHOB", 3.2);
getRealProperty
public double getRealProperty(java.lang.String name)
- get a real value already set with setRealProperty(); if name
is not found, returns Double.NaN;
getAminoAcid
public static AminoAcid getAminoAcid(java.lang.String code)
- get AminoAcid, hashed by one-letter or three-letter codes
getFullName
public static java.lang.String getFullName(java.lang.String code)
- get fullname from code; returns null if not found
getSMILES
public static java.lang.String getSMILES(java.lang.String code)
- get SMILES from code; returns null if not found
getMonomerMolWt
public static double getMonomerMolWt(java.lang.String code)
- get molecular weight of 'monomer': -N-CH(R)-C(=O)- (i.e. missing
OH2. These monomers can be combined to give the molecular weight of a
peptide. Neutral monomers are used. unknown code returns 0.0;
get3Letter
public static java.lang.String get3Letter(java.lang.String code)
- if the arg is 1-letter, return the 3-letter, else return unchanged;
unknown 1-letter returns "UNK"
get1Letter
public static java.lang.String get1Letter(java.lang.String code)
- return 1-letter code if valid 3-letter arg, else "?"
get3LetterSequence
public static java.lang.String[] get3LetterSequence(java.lang.String s1)
- get an array of 3-letter Strings from a string of 1-letters; gaps are skipped
get1LetterSequence
public static java.lang.String get1LetterSequence(java.lang.String[] s3)
- get a gapless string of 1-letter codes from an array of 3-letter Strings
getPAM250
public int getPAM250(AminoAcid a1, AminoAcid a2)
- returns score for a1 replacing a2 (from W.A.Pearson, Methods in
Enzymology, (e.d R.Doolittle) ISBN 0-12-182084-X, Academic Press,
San Diego, 183, (1990) 63-98
Not yet written
debug
public void debug()
main
public static void main(java.lang.String[] args)
- a test program on a nonsense sequence
|
|||||||||
| Home >> All >> org >> xmlcml >> [ molutil overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.xmlcml.molutil.AminoAcid