Class BasicCharacterStateMatrix<S>
java.lang.Object
org.forester.evoinference.matrix.character.BasicCharacterStateMatrix<S>
- All Implemented Interfaces:
CharacterStateMatrix<S>
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.forester.evoinference.matrix.character.CharacterStateMatrix
CharacterStateMatrix.BinaryStates, CharacterStateMatrix.Format, CharacterStateMatrix.GainLossStates, CharacterStateMatrix.NucleotideStates
-
Constructor Summary
ConstructorDescriptionBasicCharacterStateMatrix
(int number_of_identifiers, int number_of_characters) BasicCharacterStateMatrix
(int number_of_identifiers, int number_of_characters, S default_state) BasicCharacterStateMatrix
(List<List<S>> states) BasicCharacterStateMatrix
(S[][] states) -
Method Summary
Modifier and TypeMethodDescriptionboolean
containsCharacter
(String character) boolean
containsIdentifier
(String identifier) copy()
boolean
getCharacter
(int character_index) int
getCharacterIndex
(String character) getIdentifier
(int identifier_index) int
getIdentifierIndex
(String identifier) int
int
getState
(int identifier_index, int character_index) boolean
isEmpty()
pivot()
void
setCharacter
(int character_index, String character) void
setIdentifier
(int identifier_index, String identifier) void
void
void
void
void
toWriter
(Writer writer, CharacterStateMatrix.Format format) void
void
void
void
-
Constructor Details
-
BasicCharacterStateMatrix
public BasicCharacterStateMatrix(int number_of_identifiers, int number_of_characters) -
BasicCharacterStateMatrix
public BasicCharacterStateMatrix(int number_of_identifiers, int number_of_characters, S default_state) -
BasicCharacterStateMatrix
-
BasicCharacterStateMatrix
-
-
Method Details
-
containsCharacter
- Specified by:
containsCharacter
in interfaceCharacterStateMatrix<S>
-
containsIdentifier
- Specified by:
containsIdentifier
in interfaceCharacterStateMatrix<S>
-
copy
- Specified by:
copy
in interfaceCharacterStateMatrix<S>
-
equals
-
getCharacter
- Specified by:
getCharacter
in interfaceCharacterStateMatrix<S>
-
getCharacterIndex
- Specified by:
getCharacterIndex
in interfaceCharacterStateMatrix<S>
-
getIdentifier
- Specified by:
getIdentifier
in interfaceCharacterStateMatrix<S>
-
getIdentifierIndex
- Specified by:
getIdentifierIndex
in interfaceCharacterStateMatrix<S>
-
getNumberOfCharacters
public int getNumberOfCharacters()- Specified by:
getNumberOfCharacters
in interfaceCharacterStateMatrix<S>
-
getNumberOfIdentifiers
public int getNumberOfIdentifiers()- Specified by:
getNumberOfIdentifiers
in interfaceCharacterStateMatrix<S>
-
getState
- Specified by:
getState
in interfaceCharacterStateMatrix<S>
-
getState
- Specified by:
getState
in interfaceCharacterStateMatrix<S>
-
getState
- Specified by:
getState
in interfaceCharacterStateMatrix<S>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceCharacterStateMatrix<S>
-
pivot
- Specified by:
pivot
in interfaceCharacterStateMatrix<S>
-
setCharacter
- Specified by:
setCharacter
in interfaceCharacterStateMatrix<S>
-
setIdentifier
- Specified by:
setIdentifier
in interfaceCharacterStateMatrix<S>
-
setState
- Specified by:
setState
in interfaceCharacterStateMatrix<S>
-
setState
- Specified by:
setState
in interfaceCharacterStateMatrix<S>
-
setState
- Specified by:
setState
in interfaceCharacterStateMatrix<S>
-
toWriter
- Specified by:
toWriter
in interfaceCharacterStateMatrix<S>
- Throws:
IOException
-
toWriter
- Specified by:
toWriter
in interfaceCharacterStateMatrix<S>
- Throws:
IOException
-
writeNexusBinaryChractersBlock
- Throws:
IOException
-
writeNexusCharstatelabels
- Throws:
IOException
-
writeNexusMatrix
- Throws:
IOException
-
writeNexusTaxaBlock
- Throws:
IOException
-