Class LogNormalRNG

java.lang.Object
dev.nm.stat.random.rng.univariate.LogNormalRNG
All Implemented Interfaces:
RandomNumberGenerator, Seedable

public class LogNormalRNG extends Object implements RandomNumberGenerator
This random number generator samples from the log-normal distribution.

The R equivalent class are dlnorm, plnorm, qlnorm, rlnorm.

See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    LogNormalRNG(double logMean, double logSigma)
    Construct a random number generator to sample from the log-normal distribution.
    Construct a random number generator to sample from the log-normal distribution.
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    Get the next random double.
    void
    seed(long... seeds)
    Seed the random number/vector/scenario generator to produce repeatable experiments.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • LogNormalRNG

      public LogNormalRNG(NormalRNG rnorm)
      Construct a random number generator to sample from the log-normal distribution.
      Parameters:
      rnorm - a random number generator that samples from the normal distribution
    • LogNormalRNG

      public LogNormalRNG(double logMean, double logSigma)
      Construct a random number generator to sample from the log-normal distribution.
      Parameters:
      logMean - the log of mean
      logSigma - the log of standard deviation
  • Method Details

    • seed

      public void seed(long... seeds)
      Description copied from interface: Seedable
      Seed the random number/vector/scenario generator to produce repeatable experiments.
      Specified by:
      seed in interface Seedable
      Parameters:
      seeds - the seeds
    • nextDouble

      public double nextDouble()
      Description copied from interface: RandomNumberGenerator
      Get the next random double.
      Specified by:
      nextDouble in interface RandomNumberGenerator
      Returns:
      the next random number