public double[] getConditionalDistribution(int[] sequence, int position) {
    double[] result = scoresOf(sequence, position);
    ArrayMath.logNormalize(result);
    // System.out.println("marginal:          " + ArrayMath.toString(marginal,
    // nf));
    // System.out.println("conditional:       " + ArrayMath.toString(result,
    // nf));
    result = ArrayMath.exp(result);
    // System.out.println("conditional:       " + ArrayMath.toString(result,
    // nf));
    return result;
  }
public double [ ] getConditionalDistribution ( int [ ] sequence , int position ) { double [ ] result = scoresOf ( sequence , position ) ; ArrayMath . logNormalize ( result ) ; result = ArrayMath . exp ( result ) ; return result ; }
Computes the distribution over values of the element at position pos in the
sequence, conditioned on the values of the elements in all other positions
of the provided sequence.

@param sequence
the sequence containing the rest of the values to condition on
@param position
the position of the element to give a distribution for
@return an array of type double, representing a probability distribution;
sums to 1.0