Package org.drip.measure.continuous
Class R1Univariate
java.lang.Object
org.drip.measure.continuous.R1Univariate
- Direct Known Subclasses:
BoundedUniformIntegerDistribution
,PoissonDistribution
,R1Central
,R1CentralCLTProxy
,R1CentralFisherProxy
,R1NonCentral
,R1ParetoDistribution
,R1PowerLawDistribution
,R1RateDistribution
,R1ScaledDistribution
,R1ShapeScaleDistribution
,R1Uniform
,R1UnivariateNormal
,R1UnivariateUniform
,R1WilsonHilferty
,TwoIIDSum
public abstract class R1Univariate
extends java.lang.Object
R1Univariate exposes the Base Abstract Class behind Univariate R1 Distributions. It
exports the Methods for incremental, cumulative, and inverse cumulative distribution densities.
- Module = Computational Core Module
- Library = Numerical Analysis Library
- Project = Rd Continuous/Discrete Probability Measures
- Package = R1 and Rd Continuous Random Measure
- Author:
- Lakshmi Krishnamurthy
-
Constructor Summary
Constructors Constructor Description R1Univariate()
-
Method Summary
Modifier and Type Method Description double
bPOE(double x)
Retrieve the Buffered Probability of Existencedouble
centralMoment(int n)
Retrieve the nth Central Momentabstract double
cumulative(double dblX)
Compute the cumulative under the distribution to the given valuedouble
cvar(double p)
Retrieve the Quantile CVaR (Conditional Value-at-Risk) of the Distributionabstract double
density(double dblX)
Compute the Density under the Distribution at the given Variatedouble
differentialEntropy()
Retrieve the Differential Entropy of the Distributiondouble
excessKurtosis()
Retrieve the Excess Kurtosis of the Distributiondouble
expectedShortfall(double p)
Retrieve the Quantile ES (Expected Shortfall) of the Distributiondouble
fisherInformation()
Retrieve the Fisher Information of the DistributionArray2D
histogram()
Retrieve the Univariate Weighted Histogramdouble
incremental(double dblXLeft, double dblXRight)
Compute the Incremental under the Distribution between the 2 variatesdouble
invCumulative(double p)
Compute the inverse cumulative under the distribution corresponding to the given valuedouble
iqr()
Retrieve the Inter-quantile Range (IQR) of the Distributiondouble
kullbackLeiblerDivergence(R1Univariate r1UnivariateOther)
Compute the Kullback-Leibler Divergence against the other R1 Distributionabstract double
mean()
Retrieve the Mean of the Distributiondouble
median()
Retrieve the Median of the Distributiondouble
mode()
Retrieve the Mode of the DistributionR1ToR1
momentGeneratingFunction()
Construct the Moment Generating Functiondouble
nonCentralMoment(int n)
Retrieve the nth Non-central MomentPopulationCentralMeasures
populationCentralMeasures()
Retrieve the Population Central MeasuresR1ToR1
probabilityGeneratingFunction()
Construct the Probability Generating Functiondouble
quantile(double p)
Retrieve the Quantile Variate of the Distributiondouble
random()
Generate a Random Variable corresponding to the Distributiondouble[]
randomArray(int arrayCount)
Retrieve the Array of Generated Random Variablesdouble
skewness()
Retrieve the Skewness of the Distributionabstract double[]
support()
Lay out the Support of the PDF Rangeboolean
supported(double x)
Indicate if x is inside the Supported Rangedouble
tukeyAnomaly()
Retrieve the Tukey Anomaly of the Distributiondouble
tukeyCriterion()
Retrieve the Tukey Criterion of the Distributionabstract double
variance()
Retrieve the Variance of the DistributionMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
R1Univariate
public R1Univariate()
-
-
Method Details
-
support
public abstract double[] support()Lay out the Support of the PDF Range- Returns:
- Support of the PDF Range
-
supported
public boolean supported(double x)Indicate if x is inside the Supported Range- Parameters:
x
- X- Returns:
- TRUE - x is inside of the Supported Range
-
density
public abstract double density(double dblX) throws java.lang.ExceptionCompute the Density under the Distribution at the given Variate- Parameters:
dblX
- Variate at which the Density needs to be computed- Returns:
- The Density
- Throws:
java.lang.Exception
- Thrown if the input is invalid
-
cumulative
public abstract double cumulative(double dblX) throws java.lang.ExceptionCompute the cumulative under the distribution to the given value- Parameters:
dblX
- Variate to which the cumulative is to be computed- Returns:
- The cumulative
- Throws:
java.lang.Exception
- Thrown if the inputs are invalid
-
incremental
public double incremental(double dblXLeft, double dblXRight) throws java.lang.ExceptionCompute the Incremental under the Distribution between the 2 variates- Parameters:
dblXLeft
- Left Variate to which the cumulative is to be computeddblXRight
- Right Variate to which the cumulative is to be computed- Returns:
- The Incremental under the Distribution between the 2 variates
- Throws:
java.lang.Exception
- Thrown if the inputs are invalid
-
invCumulative
public double invCumulative(double p) throws java.lang.ExceptionCompute the inverse cumulative under the distribution corresponding to the given value- Parameters:
p
- Value corresponding to which the inverse cumulative is to be computed- Returns:
- The inverse cumulative
- Throws:
java.lang.Exception
- Thrown if the Input is invalid
-
mean
public abstract double mean() throws java.lang.ExceptionRetrieve the Mean of the Distribution- Returns:
- The Mean of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Mean cannot be estimated
-
median
public double median() throws java.lang.ExceptionRetrieve the Median of the Distribution- Returns:
- The Median of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Median cannot be estimated
-
quantile
public double quantile(double p) throws java.lang.ExceptionRetrieve the Quantile Variate of the Distribution- Parameters:
p
- The Quantile Fraction- Returns:
- The Quantile Variate of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Quantile Variate cannot be estimated
-
mode
public double mode() throws java.lang.ExceptionRetrieve the Mode of the Distribution- Returns:
- The Mode of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Mode cannot be estimated
-
variance
public abstract double variance() throws java.lang.ExceptionRetrieve the Variance of the Distribution- Returns:
- The Variance of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Variance cannot be estimated
-
skewness
public double skewness() throws java.lang.ExceptionRetrieve the Skewness of the Distribution- Returns:
- The Skewness of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Skewness cannot be estimated
-
excessKurtosis
public double excessKurtosis() throws java.lang.ExceptionRetrieve the Excess Kurtosis of the Distribution- Returns:
- The Excess Kurtosis of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Skewness cannot be estimated
-
differentialEntropy
public double differentialEntropy() throws java.lang.ExceptionRetrieve the Differential Entropy of the Distribution- Returns:
- The Differential Entropy of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Entropy cannot be estimated
-
momentGeneratingFunction
Construct the Moment Generating Function- Returns:
- The Moment Generating Function
-
probabilityGeneratingFunction
Construct the Probability Generating Function- Returns:
- The Probability Generating Function
-
fisherInformation
public double fisherInformation() throws java.lang.ExceptionRetrieve the Fisher Information of the Distribution- Returns:
- The Fisher Information of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Fisher Information cannot be estimated
-
kullbackLeiblerDivergence
Compute the Kullback-Leibler Divergence against the other R1 Distribution- Parameters:
r1UnivariateOther
- Other R1 Distribution- Returns:
- Kullback-Leibler Divergence against the other R1 Distribution
- Throws:
java.lang.Exception
- Thrown if the Kullback-Leibler Divergence cannot be estimated
-
cvar
public double cvar(double p) throws java.lang.ExceptionRetrieve the Quantile CVaR (Conditional Value-at-Risk) of the Distribution- Parameters:
p
- The Quantile- Returns:
- The Quantile CVaR of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Quantile CVaR cannot be estimated
-
expectedShortfall
public double expectedShortfall(double p) throws java.lang.ExceptionRetrieve the Quantile ES (Expected Shortfall) of the Distribution- Parameters:
p
- The Quantile- Returns:
- The Quantile ES of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Quantile ES cannot be estimated
-
bPOE
public double bPOE(double x) throws java.lang.ExceptionRetrieve the Buffered Probability of Existence- Parameters:
x
- The Variate- Returns:
- The Buffered Probability of Existence
- Throws:
java.lang.Exception
- Thrown if the Buffered Probability of Existence cannot be estimated
-
nonCentralMoment
public double nonCentralMoment(int n) throws java.lang.ExceptionRetrieve the nth Non-central Moment- Parameters:
n
- Moment Number- Returns:
- The nth Non-central Moment
- Throws:
java.lang.Exception
- Thrown if the nth Non-central Moment cannot be estimated
-
centralMoment
public double centralMoment(int n) throws java.lang.ExceptionRetrieve the nth Central Moment- Parameters:
n
- Moment Number- Returns:
- The nth Central Moment
- Throws:
java.lang.Exception
- Thrown if the nth Central Moment cannot be estimated
-
iqr
public double iqr() throws java.lang.ExceptionRetrieve the Inter-quantile Range (IQR) of the Distribution- Returns:
- The Inter-quantile Range of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Inter-quantile Range cannot be estimated
-
tukeyCriterion
public double tukeyCriterion() throws java.lang.ExceptionRetrieve the Tukey Criterion of the Distribution- Returns:
- The Tukey Criterion of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Tukey Criterion cannot be estimated
-
tukeyAnomaly
public double tukeyAnomaly() throws java.lang.ExceptionRetrieve the Tukey Anomaly of the Distribution- Returns:
- The Tukey Anomaly of the Distribution
- Throws:
java.lang.Exception
- Thrown if the Tukey Anomaly cannot be estimated
-
random
public double random() throws java.lang.ExceptionGenerate a Random Variable corresponding to the Distribution- Returns:
- Random Variable corresponding to the Distribution
- Throws:
java.lang.Exception
- Thrown if the Random Instance cannot be estimated
-
randomArray
public double[] randomArray(int arrayCount)Retrieve the Array of Generated Random Variables- Parameters:
arrayCount
- Number of Elements- Returns:
- Array of Generated Random Variables
-
populationCentralMeasures
Retrieve the Population Central Measures- Returns:
- The Population Central Measures
-
histogram
Retrieve the Univariate Weighted Histogram- Returns:
- The Univariate Weighted Histogram
-