|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.Vector
de.unibi.techfak.jpredictor.motifs.MotifList
public class MotifList
Stores motifs in a Vector.
| Field Summary | |
|---|---|
static Motif |
motifDSP1
An instance of the DSP1 binding site motif. |
static Motif |
motifEN1
An instance of the engrailed 1 motif. |
static Motif |
motifG10
An instance of the long GAF binding site motif. |
static Motif |
motifGA
An instance of the GAF binding site motif. |
static Motif |
motifGT
An instance of an enriched site in the predicted PRE/TREs. |
static Motif |
motifPF
An instance of the right hand sided PHO binding site. |
static DoubleMotif |
motifPHO_DSP1
The conjunction of the core PHO binding site and the DSP1 motif as it was reported by Dejardin in 2005. |
static Motif |
motifPHOcore
The core of the PHO (Pleiohomeotic) binding site. |
static Motif |
motifPM
An instance of the long PHO binding site motif. |
static Motif |
motifPS
An instance of the core PHO binding site motif. |
static Motif |
motifT
An instance of an enriched site in the predicted PRE/TREs. |
static Motif |
motifTGC
An instance of an enriched site in the predicted PRE/TREs. |
static Motif |
motifZ
An instance of the Zeste binding site motif. |
| Fields inherited from class java.util.Vector |
|---|
capacityIncrement, elementCount, elementData |
| Fields inherited from class java.util.AbstractList |
|---|
modCount |
| Constructor Summary | |
|---|---|
MotifList()
Simple Constructor which inits the underlying vector to hold 10 objects and to increase the size in steps of 10 |
|
| Method Summary | |
|---|---|
boolean |
addCheck(int index,
Motif m)
Iff the motif is not present in this motif list, it is added. |
int |
checkWeights()
Checks the weights of the motifs for either infinity or not-a-number. |
int |
clearMark(int mark,
int depth)
Clears the mark in all motifs and child motifs in the list. |
int |
containsMotif(Motif m)
Checks whether the given motif is already present in the motif list by comparing motif references. |
int |
countMotifByName(java.lang.String name,
int depth)
Searches this MotifList and the MultiMotif's
motifs and counts the motifs matching the given name. |
static MotifList |
defaultDoubleMotifs()
Creates the DoubleMotifs from the default single motifs
and assigns them a weight (which is got from running the jPREdictor
with the 'new_pre.fasta' as model and the 'non_pre.fasta' as
background). |
static MotifList |
defaultMotifs()
Creates and returns the default motifs, what are "1" ("GSNMACGCCCC", one error allowed), "G10" ("GAGAGAGAGA", one error allowed), "GA" ("GAGAG"), "PF" ("GCCATHWY"), "PM" ("CNGCCATNDNND"), "PS" ("GCCAT"), "Z" ("YGAGYG"). |
static MotifList |
extendedDoubleMotifs()
Creates the DoubleMotifs from the extended single motifs
and assigns them a weight (which is got from running the jPREdictor
with the 'new_pre.fasta' as model and the 'non_pre.fasta' as
background). |
static MotifList |
extendedMotifs()
Creates and returns the list of extended (additional) motifs, which are "DSP1" ("GAAAA"), "GT" ("GTGTGYGWGTG"), "T" ("WTDWWTWTYHTT"), "TGC" ("YGYTGCYGYDS"). |
Motif |
findMotifByName(java.lang.String name,
int fromIndex,
int searchDepth,
int returnDepth)
Searches this MotifList and the MultiMotifs
motifs for the given name. |
MotifList |
getSingleMotifs()
Extracts from all motifs in this list the single motifs
and stores them in a new MotifList. |
MotifList |
getUniqueMotifs()
Extracts every unique motif and stores them in a new list. |
int |
initSearch(java.lang.CharSequence sequence)
Calls initSearch for all motifs stored in this Vector. |
MotifList |
join(MotifList coll)
Adds all elements from coll to this
MotifList. |
static PSSMotif |
motifPssmPHO()
Creates the PHO motif as a PSSM. |
static MotifList |
narDoubleMotifs()
Returns the DoubleMotifs for the prediction made
in 2006/04 by Fiedler, 2006, NAR web server issue. |
boolean |
replaceMarkedMotifs(Motif motif,
int depth,
int mark)
Replaces all motifs, that bear the mark with the given one. |
boolean |
replaceMotifs(java.lang.String name,
Motif motif,
int depth)
Replaces one motif with another one in all instances and occurrences. |
int |
searchMotifByName(java.lang.String name,
int fromIndex)
Searches this MotifList, until a Motif was found,
that matches the given name. |
int |
searchMotifByNameRecursive(java.lang.String name,
int fromIndex)
Searches this MotifList and the MultiMotifs
motifs for the given name. |
int |
searchMotifByReference(Motif m,
int fromIndex)
Searches this MotifList for the given Motif by comparing
references. |
void |
setMark(int mark,
int depth)
Sets the mark in all motifs and child motifs in the list. |
int |
setScores(java.util.Vector[] posOcc,
java.util.Vector[] negOcc)
Sets the log-odd-scores (weights) for the motifs in this motif list. |
void |
sortForWeight(int keep)
Sorts the motifs in this list according to their weight. |
| Methods inherited from class java.util.Vector |
|---|
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize |
| Methods inherited from class java.util.AbstractList |
|---|
iterator, listIterator, listIterator |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
iterator, listIterator, listIterator |
| Field Detail |
|---|
public static final Motif motifEN1
defaultMotifs()public static final Motif motifG10
defaultMotifs()public static final Motif motifGA
defaultMotifs()public static final Motif motifPF
defaultMotifs()public static final Motif motifPM
defaultMotifs()public static final Motif motifPS
defaultMotifs()public static final Motif motifZ
defaultMotifs()public static final Motif motifDSP1
DoubleMotif is build from this, too.
extendedMotifs()public static final Motif motifGT
extendedMotifs()public static final Motif motifT
extendedMotifs()public static final Motif motifTGC
extendedMotifs().
public static final Motif motifPHOcore
newMotifs() is called.
public static final DoubleMotif motifPHO_DSP1
| Constructor Detail |
|---|
public MotifList()
| Method Detail |
|---|
public static final PSSMotif motifPssmPHO()
public static MotifList defaultMotifs()
MotifList containing the default
single motifs as RegularExpressionMotifs.public static MotifList extendedMotifs()
MotifList containing additional
single motifs as RegularExpressionMotifs.public static MotifList defaultDoubleMotifs()
DoubleMotifs from the default single motifs
and assigns them a weight (which is got from running the jPREdictor
with the 'new_pre.fasta' as model and the 'non_pre.fasta' as
background). Not all pairs are built, because permutations are
forbidden.
MotifList containing the default
double motifs as DoubleMotifs.public static MotifList extendedDoubleMotifs()
DoubleMotifs from the extended single motifs
and assigns them a weight (which is got from running the jPREdictor
with the 'new_pre.fasta' as model and the 'non_pre.fasta' as
background). Not all pairs are built, because permutations are
forbidden.
MotifList containing the extended
double motifs as DoubleMotifs.public static MotifList narDoubleMotifs()
Returns the DoubleMotifs for the prediction made
in 2006/04 by Fiedler, 2006, NAR web server issue. The weights
for the motifs come from analyzing the original training sets,
'new_pre.fasta' as model and the 'non_pre.fasta' as background.
The motif list contains of DoubleMotifs with distance
(0,219) of the single motifs En1, GAF, G10, PHO-DSP1, pssmPHO and Z.
MotifList containing the double
motifs used in the PRE/TRE prediction by Fiedler, 2006.
public boolean addCheck(int index,
Motif m)
equals(Object) for every
motif in the list.
index - The index in the list, where the motif should be added.
Give -1 to append.m - The new motif to be added.
true iff the motif was added, false
otherwise.- See Also:
Motif.equals(Object)public MotifList join(MotifList coll)
coll to this
MotifList. If coll and
this specify the same MotifList,
the elements' references are doubled. This behaviour
differs from the one shown by addAll(Collection),
where the result is undefined in that specific case. coll is null, this
MotifList remains unchanged.
coll - The list of motifs to be added to this list.
this.public int initSearch(java.lang.CharSequence sequence)
initSearch for all motifs stored in this Vector.
public void setMark(int mark,
int depth)
If depth is zero, only the motifs in this list get
the mark set, otherwise the MultiMotif
s in the list are processed too. Set depth to -1,
if no restrictions to the depth level are wanted.
mark - The mark to be set.depth - Specifies the level down to which MultiMotifs
are to be expanded.
public int clearMark(int mark,
int depth)
If depth is zero, only the motifs in the list are
cleared from their marks, otherwise the MultiMotif
s in the list are processed too. Set depth to -1,
if no restrictions to the depth level are wanted.
mark - The mark to be cleared. Set it to -1 to clear all
marks.depth - Specifies the level down to which MultiMotifs
are to be expanded.
public int searchMotifByName(java.lang.String name,
int fromIndex)
MotifList, until a Motif was found,
that matches the given name. The match method used
is String.compareToIgnoreCases( String ).
name - The name of the motif to find.fromIndex - The first index to start the search. If it is
negative it is set to zero.
name==null.
public int searchMotifByReference(Motif m,
int fromIndex)
MotifList for the given Motif by comparing
references.
m - The motif to find.fromIndex - The first index to start the search. If it is
negative it is set to zero.
motif==null.
public int searchMotifByNameRecursive(java.lang.String name,
int fromIndex)
MotifList and the MultiMotifs
motifs for the given name. The match method used is
String.compareToIgnoreCases( String ).
name - The name of the motif to find.fromIndex - The first index to start the search. If it is
negative it is set to zero.
name==null.
public Motif findMotifByName(java.lang.String name,
int fromIndex,
int searchDepth,
int returnDepth)
MotifList and the MultiMotifs
motifs for the given name. The match method used is
String.compareToIgnoreCases( String ).
If searchDepth is zero, only the motifs in this list are
matched to the name given, otherwise the MultiMotifs in
the list are processed down to the specified depth level. If
searchDepth is -1, no restrictions to the depth level are made.
The parameter returnDepth specifies the absolute depth
of the returned motif. The depth of the returned motif is either
equal to the motif matching the name, in this case it is that motif,
or lower, in this case its a parent motif. Give -1 to ensure, that the
motif matching the name is returned.
name - The name of the motif to find.fromIndex - The first index to start the search. If it is
negative it is set to zero.searchDepth - Specifies the level down to which MultiMotifs
are to be expanded.
null,
if the motif was not found
public int countMotifByName(java.lang.String name,
int depth)
Searches this MotifList and the MultiMotif's
motifs and counts the motifs matching the given name. The match method
used is String.compareToIgnoreCases( String ). Note, that
it might happen to find a MultiMotif with the given name
and within this MultiMotif another motif with the same
name.
If depth is zero, only the motifs in the list are counted
to whether they match the given name, otherwise the MultiMotif
s in the list are processed too. Set depth to -1,
if no restrictions to the depth level are wanted.
name - The name of the motif to find.depth - The depth level within the motifs, up to which the
MultiMotif are processed too.
public int containsMotif(Motif m)
contains(Object), first, by comparing references and not
relying on the equals-method, and second, by examining
MultiMotifs deeply. This might be useful if a single motif
is searched in a motif list containing double motifs or triple motifs.
If the given motif is part of a motif in this list its number is
returned.
m - The motif to search in all motifs in this list.
public MotifList getUniqueMotifs()
MultiMotif and all motifs the multi motifs are
comprised of. No motif occurs twice in the list.
public MotifList getSingleMotifs()
this list the single motifs
and stores them in a new MotifList. No single motif
occurs twice in the new list.
public int checkWeights()
public boolean replaceMotifs(java.lang.String name,
Motif motif,
int depth)
depth is zero, only the motifs in the list are
checked whether or not they are candidates to replacement,
otherwise the MultiMotifs in the list are processed
too. Set depth to -1, if no restrictions to the depth
level are wanted.
name - The name of the motif to be replaced.motif - The motif which is the replacement.depth - The depth level within the motifs, up to which the
MultiMotif are processed too.
true if the list was changed, false
otherwise.
public boolean replaceMarkedMotifs(Motif motif,
int depth,
int mark)
depth is zero, only the motifs in the list are
checked whether or not they are candidates to replacement,
otherwise the MultiMotifs in the list are processed
too. Set depth to -1, if no restrictions to the depth
level are wanted.
motif - The motif which is the replacement.depth - The depth level within the motifs, up to which the
MultiMotifs are processed too.mark - The mark all motifs to be replaced must have.
true if the list was changed, false
otherwise.
public int setScores(java.util.Vector[] posOcc,
java.util.Vector[] negOcc)
score = ln( posOcc / nrOfPosSequ ) - ln( negOcc / nrOfNegSequ )
. Thus, a normalization by the number of sequences is always
made. The normalization by sequence length must have been done before.
Both vector arrays must be of the same length (one vector for each
motif in the motif list) and of the length of the MotifList. The
vectors must not contain others than Numbers, which
represent the occurrences of the motif on the sequence and in one array
all vectors must be of the same size. Furthermore, it is assumed, that
the arrays are in the same order the motifs in this MotifList
are.
The motif's scores are set by using Motif.setWeight(double)
. Make sure all motifs are completely defined.
posOcc - The array of vectors containing the occurrences of a
motif on the sequences of the positive training set. One vector for
every motif.negOcc - The array of vectors containing the occurrences of a
motif on the sequences of the negative training set. One vector for
every motif.
null, -2, if the lengths
of the arrays and the size of the MotifList are not the
same, -3, if some vectors are null and -4, if the vectors
are not of the same size.Motif.setWeight(double)public void sortForWeight(int keep)
keep - The number of best weighting motifs to keep. Give
a negative number to keep all motifs.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||