public class MutationMatrix extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static MutationMatrix[] |
defaultMutationMatrices
Returns the implemented default mutation matrices.
|
static MutationMatrix |
singleBaseSubstitution
Mutation matrix allowing for a single base mutation.
|
static MutationMatrix |
synonymousMutation
Mutation matrix grouping synonymous amino acids.
|
static MutationMatrix |
transitionsSingleBaseSubstitution
Mutation matrix allowing for a single base transitions mutation.
|
static MutationMatrix |
transversalSingleBaseSubstitution
Mutation matrix allowing for a single base transversion mutation.
|
Constructor and Description |
---|
MutationMatrix(String name,
String description)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
add(MutationMatrix otherMatrix)
Adds the content of a mutation matrix in this matrix.
|
void |
addMutation(Character originalAa,
Character mutatedAa)
Adds a possible mutation.
|
String |
getDescription()
Returns the description of this mutation matrix.
|
Double |
getMaxDelta()
Returns the maximum difference between an original amino acid and the mutated version.
|
Double |
getMinDelta()
Returns the minimum difference between an original amino acid and the mutated version.
|
Set<Character> |
getMutatedAminoAcids()
Returns the possible mutated amino acids.
|
HashSet<Character> |
getMutatedAminoAcids(Character originalAminoAcid)
Returns the possible mutated amino acids for the given amino acid as a
list of their single letter code.
|
HashMap<Double,HashSet<Character>> |
getMutatedMasses(Character originalAminoAcid)
Returns the possible mutated amino acids for the given amino acid as a
map where the list of their single letter code is indexed by the delta mass to the original amino acid.
|
String |
getName()
Returns the name of this mutation matrix.
|
Set<Character> |
getOriginalAminoAcids()
Returns the amino acids where a mutation has been registered.
|
HashSet<Character> |
getOriginalAminoAcids(Character mutatedAminoAcid)
Returns the possible original amino acids for the given mutated amino
acid as a list of their single letter code.
|
boolean |
isSameAs(MutationMatrix mutationMatrix)
Indicates whether the two MutationMatrix are the same.
|
void |
setDescription(String description)
Sets the description of this mutation matrix.
|
void |
setName(String name)
Sets the name of this mutation matrix.
|
public static final MutationMatrix singleBaseSubstitution
public static final MutationMatrix transitionsSingleBaseSubstitution
public static final MutationMatrix transversalSingleBaseSubstitution
public static final MutationMatrix synonymousMutation
public static final MutationMatrix[] defaultMutationMatrices
public void addMutation(Character originalAa, Character mutatedAa)
originalAa
- the original amino acid represented by its single
letter codemutatedAa
- the mutated amino acid represented by its single letter
codepublic HashMap<Double,HashSet<Character>> getMutatedMasses(Character originalAminoAcid)
originalAminoAcid
- the amino acid of interestpublic HashSet<Character> getMutatedAminoAcids(Character originalAminoAcid)
originalAminoAcid
- the amino acid of interestpublic HashSet<Character> getOriginalAminoAcids(Character mutatedAminoAcid)
mutatedAminoAcid
- the mutated amino acid of interestpublic Set<Character> getOriginalAminoAcids()
public Set<Character> getMutatedAminoAcids()
public void add(MutationMatrix otherMatrix)
otherMatrix
- the other matrix to addpublic String getName()
public void setName(String name)
name
- the name of this mutation matrixpublic String getDescription()
public void setDescription(String description)
description
- the description of this mutation matrixpublic Double getMinDelta()
public Double getMaxDelta()
public boolean isSameAs(MutationMatrix mutationMatrix)
mutationMatrix
- the mutation matrixCopyright © 2016. All rights reserved.