Codota Logo
MathUtils.gr
Code IndexAdd Codota to your IDE (free)

How to use
gr
method
in
org.canova.api.util.MathUtils

Best Java code snippets using org.canova.api.util.MathUtils.gr (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: org.nd4j/canova-api

/**
 * Returns the log-odds for a given probability.
 *
 * @param prob the probability
 * @return the log-odds after the probability has been mapped to
 * [Utils.SMALL, 1-Utils.SMALL]
 */
public static /*@pure@*/ double probToLogOdds(double prob) {
 if (gr(prob, 1) || (sm(prob, 0))) {
  throw new IllegalArgumentException("probToLogOdds: probability must " +
    "be in [0,1] " + prob);
 }
 double p = SMALL + (1.0 - 2 * SMALL) * prob;
 return Math.log(p / (1 - p));
}
origin: jpatanooga/Canova

/**
 * Returns the log-odds for a given probability.
 *
 * @param prob the probability
 *
 * @return the log-odds after the probability has been mapped to
 * [Utils.SMALL, 1-Utils.SMALL]
 */
public static /*@pure@*/ double probToLogOdds(double prob) {
  if (gr(prob, 1) || (sm(prob, 0))) {
    throw new IllegalArgumentException("probToLogOdds: probability must " +
        "be in [0,1] "+prob);
  }
  double p = SMALL + (1.0 - 2 * SMALL) * prob;
  return Math.log(p / (1 - p));
}
org.canova.api.utilMathUtilsgr

Javadoc

Tests if a is greater than b.

Popular methods of MathUtils

  • clamp
    Clamps the value to a discrete value
  • column
    This returns the given column over an n arrays
  • combination
    This returns the combination of n choose r
  • coordSplit
    This returns the coordinate split in a list of coordinates such that the values for ret[0] are the x
  • correlation
    Returns the correlation coefficient of two double vectors.
  • factorial
    This will return the factorial of the given number n.
  • idf
    Inverse document frequency: the total docs divided by the number of times the word appeared in a doc
  • log2
    Returns the logarithm of a for base 2.
  • maxIndex
    Returns index of maximum element in a given array of doubles. First maximum is returned.
  • normalize
    Normalizes the doubles in the array using the given value.
  • randomNumberBetween
    Generates a random integer between the specified numbers
  • sm
    Tests if a is smaller than b.
  • randomNumberBetween,
  • sm,
  • ssError,
  • ssReg,
  • ssTotal,
  • sum,
  • sumOfMeanDifferences,
  • sumOfMeanDifferencesOnePoint,
  • sumOfProducts

Popular in Java

  • Reactive rest calls using spring rest template
  • scheduleAtFixedRate (ScheduledExecutorService)
  • runOnUiThread (Activity)
  • getContentResolver (Context)
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now