Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## de.jstacs.motifDiscovery
Interface MutableMotifDiscoverer

All Superinterfaces:
  Cloneable, MotifDiscoverer, Storable

All Known Implementing Classes:
  HiddenMotifsMixture, IndependentProductScoringFunction

    public interface MutableMotifDiscoverer

extends MotifDiscoverer

This is the interface that any tool for de-novo motif discovery should implement that allows any modify-operations like shift, shrink and expand. These operations are possible if the motif is mutable.

Author:
  Jan Grau, Jens Keilwagen
See Also:
  `Mutable`

Nested Class Summary

Nested classes/interfaces inherited from interface de.jstacs.motifDiscovery.MotifDiscoverer
`MotifDiscoverer.KindOfProfile`

Method Summary
`int[]` | `determineNotSignificantPositionsFor(int motif, Sample[] data, double[][] weights, int classIdx)` This method determines the number of not significant positions from each side of the motif with index `motif`.
`void` | `initializeMotif(int motifIndex, Sample data, double[] weights)` This method allows to initialize the model of a motif manually using a weighted sample.
`boolean` | `modifyMotif(int motifIndex, double[] weightsLeft, double[] weightsRight, double[][][][] replacementLeft, double[][][][] replacementRight, int offsetLeft, int offsetRight)` Manually modifies the motif model with index `motifIndex`.
`boolean` | `modifyMotif(int motifIndex, int offsetLeft, int offsetRight)` Manually modifies the motif model with index `motifIndex`.

Methods inherited from interface de.jstacs.motifDiscovery.MotifDiscoverer
`getGlobalIndexOfMotifInComponent, getIndexOfMaximalComponentFor, getMotifLength, getNumberOfComponents, getNumberOfMotifs, getNumberOfMotifsInComponent, getProfileOfScoresFor, getStrandFor`

Methods inherited from interface de.jstacs.Storable
`toXML`

Method Detail

### determineNotSignificantPositionsFor

    int[] determineNotSignificantPositionsFor(int motif,
                                              Sample[] data,
                                              double[][] weights,
                                              int classIdx)

  This method determines the number of not significant positions from each side of the motif with index `motif`.

  Parameters:
    `motif` - the index of the motif in the motif discoverer
    `data` - an array `Sample`s, each array-entry represents on class
    `weights` - the weights of each `Sequence` for each class
    `classIdx` - the index of the current class in `classCounts`
  Returns:
    a two dimensional array containing at position 0 the number of not significant positions from the left and at position 1 the number of not significant positions from the right side
  See Also:
    `Mutable.determineNotSignificantPositions(double, double[], double[], double[][][][], double[][][][], double)`, `modifyMotif(int, int, int)`, `modifyMotif(int, double[], double[], double[][][][], double[][][][], int, int)`

### modifyMotif

    boolean modifyMotif(int motifIndex,
                        double[] weightsLeft,
                        double[] weightsRight,
                        double[][][][] replacementLeft,
                        double[][][][] replacementRight,
                        int offsetLeft,
                        int offsetRight)
                        throws Exception

  Manually modifies the motif model with index `motifIndex`. The two offsets `offsetLeft` and `offsetRight` define how many positions the left or right border positions shall be moved. Negative numbers indicate moves to the left while positive numbers correspond to moves to the right.

  Parameters:
    `motifIndex` - the index of the motif in the motif discoverer
    `weightsLeft` - the weights for the left contrast distributions
    `weightsRight` - the weights for the right contrast distributions
    `replacementLeft` - the replacement distribution for the left side
    `replacementRight` - the replacement distribution for the right side
    `offsetLeft` - the offset on the left side
    `offsetRight` - the offset on the right side
  Returns:
    `true` if the motif model was modified otherwise `false`
  Throws:
    `Exception`

### modifyMotif

    boolean modifyMotif(int motifIndex,
                        int offsetLeft,
                        int offsetRight)
                        throws Exception

  Manually modifies the motif model with index `motifIndex`. The two offsets `offsetLeft` and `offsetRight` define how many positions the left or right border positions shall be moved. Negative numbers indicate moves to the left while positive numbers correspond to moves to the right. The distribution for sequences to the left and right side of the motif shall be computed internally.

  Parameters:
    `motifIndex` - the index of the motif in the motif discoverer
    `offsetLeft` - the offset on the left side
    `offsetRight` - the offset on the right side
  Returns:
    `true` if the motif model was modified otherwise `false`
  Throws:
    `Exception`
  See Also:
    `modifyMotif(int, double[], double[], double[][][][], double[][][][], int, int)`

### initializeMotif

    void initializeMotif(int motifIndex,
                         Sample data,
                         double[] weights)
                         throws Exception

  This method allows to initialize the model of a motif manually using a weighted sample.

  Parameters:
    `motifIndex` - the index of the motif in the motif discoverer
    `data` - the sample of sequences
    `weights` - either `null` or an array of length `data.getNumberofElements()` with non-negative weights.
  Throws:
    `Exception` - if initialize was not possible

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD