This package is not intended to have strong biological ties. It is here to make programming things like dynamic-programming much easier. It also handles serialization of well-known alphabets so that applicable singleton properties of alphabets and Symbols are maintained.
All coordinates are in 'bio-coordinates' - that is - legal indexes start from 1 and a range is inclusive (4 to 7 includes 4, 5, 6 and 7).
A Symbol is a single token. The Symbol maintains a name, a token (char), and an Annotation bundle. A set of Symbols is represented by an Alphabet instance. If the Alphabet can guarantee that there are only ever a finite number of Symbols contained with in it, then it must implement FiniteAlphabet. The Symbol objects within a FiniteAlphabet can be tested for equality by comparing their references directly. A SymbolList is a string over the Symbols from a single Alphabet instance. This allows you to represent a sequence of tokens, such as DNA nucleotides, or stock-market prices.
CrossProductAlphabet and CrossProductSymbol allow alphabets and symbols to be represented that are the combination of two or more alphabets and symbols under cross-product. For example, the CrossProduct alphabet DNA x DNA would contain all di-nucleotides. DNA x DNA x DNA x Protein would contain all combinations of three nucleotides and a single amino-acid. Dice x Coin would contain every possible combination of dice roles (1..6) and of coin flips (Heads, Tails) as the Symbol objects (1, Heads), (1, Tails), (2, Heads) ... (6, Tails). If any one of the Alphabets that make up the source of a CrossProductAlphabet is not finite, then the resulting CrossProductAlphabet will not be finite either.
Locations within a SymbolList can be represented by a Location object. This interface defines a sub-set of points that are within the Location. This uses bio-coordinates, and defines all the operations that you are likely to need to build your own Locations (union, intersection and the like).
Interface Summary Interface Description AlphabetThe set of AtomicSymbols which can be concatenated together to make a SymbolList. AlphabetIndexMap between Symbols and index numbers. AtomicSymbolA symbol that is not ambiguous. BasisSymbolA symbol that can be represented as a string of Symbols. CodonPref CodonPrefFilter FiniteAlphabetAn alphabet over a finite set of Symbols. FuzzyLocation.RangeResolverDetermines how a
FuzzyLocationshould be treated when used as a normal
FuzzyPointLocation.PointResolverDetermines how a
FuzzyPointLocationshould be treated when used as a normal
GappedSymbolListThis extends SymbolList with API for manipulating, inserting and deleting gaps. LocationA set of integers, often used to represent positions on biological sequences. ManyToOneTranslationTableA translation table that will handle the many-to-one mappings that you see, for example, with genetic codes. PackingAn encapsulation of the way symbols map to bit-patterns. ReversibleTranslationTableA translation table that can also translate from the target to source alphabet. SoftMaskedAlphabet.MaskingDetectorImplementations will define how soft masking looks. SymbolA single symbol. SymbolListA sequence of symbols that belong to an alphabet. SymbolListFactoryThis interface exists to hide implementational details of SymbolLists when making chunked symbol lists. SymbolPropertyTableclass for maintaining properties associated with a symbol TranslationTableEncapsulates the mapping from a source to a destination alphabet. WobbleDistributionan object to return statistics about the frequency of the wobble base in a set of synonymous codons.
Class Summary Class Description AbstractAlphabetAn abstract implementation of
AbstractLocationAn abstract implementation of
AbstractManyToOneTranslationTablean abstract class implementing basic functionality of a translation table that translates Symbols from one Alphabet to another. AbstractRangeLocationBase class for simple contiguous Location implementations. AbstractReversibleTranslationTablean abstract class implementing basic functionality of a translation table that translates Symbols from one Alphabet to another. AbstractSymbolThe base-class for Symbol implementations. AbstractSymbolListAbstract helper implementation of the SymbolList core interface. AlphabetManagerUtility methods for working with Alphabets. BetweenLocationBetween view onto an underlying Location instance. ChunkedSymbolListSymbolList implementation using constant-size chunks. CircularLocationCircular view onto an underlying Location instance. CodonPrefFilter.AcceptAll CodonPrefFilter.ByName CodonPrefFilter.EverythingToXML CodonPrefToolsAn utility class for codon preferences DNAAmbPackPacking utility class for DNA. DNANoAmbPackA
Packingimplementation which handles the DNA alphabet, without any support for ambiguity symbols.
DoubleAlphabetAn efficient implementation of an Alphabet over the infinite set of double values. DoubleAlphabet.DoubleRangeA range of double values. DoubleAlphabet.DoubleSymbolA single double value. DoubleAlphabet.SubDoubleAlphabetA class to represent a contiguous range of double symbols. DummySymbolListSymbol list which just consists of non-informative symbols. EditEncapsulates an edit operation on a SymbolList. FundamentalAtomicSymbolAn atomic symbol consisting only of itself. FuzzyLocationA 'fuzzy' location a-la Embl fuzzy locations. FuzzyPointLocation
FuzzyPointLocationrepresents two types of EMBL-style partially-defined locations.
IntegerAlphabetAn efficient implementation of an Alphabet over the infinite set of integer values. IntegerAlphabet.IntegerSymbolA single int value. IntegerAlphabet.SubIntegerAlphabetA class to represent a finite contiguous subset of the infinite IntegerAlphabet LocationToolsTools class containing a number of operators for working with
MergeLocationProduced by LocationTools as a result of union operations. MotifTools
MotifToolscontains utility methods for sequence motifs.
PackedSymbolListA SymbolList that stores symbols as bit-patterns in an array of longs. PackedSymbolListFactoryThis class makes PackedSymbolLists. PackingFactoryA factory that is used to maintain associations between alphabets and preferred bit-packings for them. PointLocationA location representing a single point. RangeLocationA simple implementation of Location that contains all points between getMin and getMax inclusive. RelabeledAlignmentAn alignment that relabels another alignment. SimpleAlphabetA simple no-frills implementation of the FiniteAlphabet interface. SimpleAtomicSymbolA basic implementation of AtomicSymbol. SimpleCodonPrefa simple no-frills implementation of the CodonPref object that encapsulates codon preference data. SimpleGappedSymbolListThis implementation of GappedSymbolList wraps a SymbolList, allowing you to insert gaps. SimpleGappedSymbolList.BlockAn aligned block. SimpleGeneticCodeTableA genetic code translation table representing a translation table in the DDBJ/EMBL/GenBank Feature Table (appendix V). SimpleManyToOneTranslationTableA no-frills implementation of a translation table that maps between two alphabets. SimpleReversibleTranslationTableA no-frills implementation of TranslationTable that uses a Map to map from symbols in a finite source alphabet into a target alphabet. SimpleSymbolListBasic implementation of SymbolList. SimpleSymbolListFactoryThis class makes SimpleSymbolLists. SimpleSymbolPropertyTableClass that implements the SymbolPropertyTable interface SimpleTranslationTableA no-frills implementation of TranslationTable that uses a Map to map from symbols in a finite source alphabet into a target alphabet. SingletonAlphabetAn alphabet that contains a single atomic symbol. SoftMaskedAlphabetSoft masking is usually displayed by making the masked regions somehow different from the non masked regions. SoftMaskedAlphabet.MaskingDetector.DefaultMaskingDetector SuffixTreeSuffix tree implementation. SuffixTree.SuffixNodeA node in the suffix tree. SymbolListViewsTools class for constructing views of
UkkonenSuffixTreeA suffix tree is an efficient method for encoding the frequencies of motifs in a sequence. UkkonenSuffixTree.SuffixNodeend Tree modification methods
Exception Summary Exception Description IllegalAlphabetExceptionThe exception to indicate that an invalid alphabet has been used. IllegalSymbolExceptionThe exception to indicate that a symbol is not valid within a context.