Package jdistlib
Class Kendall
java.lang.Object
jdistlib.generic.GenericDistribution
jdistlib.Kendall
Kendall tau distribution
-
Field Summary
FieldsFields inherited from class jdistlib.generic.GenericDistribution
random -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic final doublecalculate_count(double tau, int n) static final doublecalculate_tau(double x, int n) doublecumulative(double p, boolean lower_tail, boolean log_p) static final doublecumulative(double x, int n) Cumulative density function of Kendall distribution.static final doublecumulative_tau(double tau, int n) Cumulative distribution of Kendall distributiondoubledensity(double x, boolean log) static final doubledensity(double x, int n) Density of Kendall distributionstatic final doubledensity_tau(double tau, int n) Density of Kendall distributiondoublequantile(double q, boolean lower_tail, boolean log_p) static final doublequantile(double p, int n) Quantile search.static final doublequantile_tau(double p, int n) doublerandom()static final double[]random(int count, int n, RandomEngine random) static final doublerandom(int n, RandomEngine random) Kendall RNG by inversionMethods inherited from class jdistlib.generic.GenericDistribution
copyBackward, cumulative, cumulative, cumulative, cumulative_hazard, cumulative_hazard, cumulativeInto, density, density, densityInto, getRandomEngine, hazard, hazard, inverse_survival, inverse_survival, quantile, quantile, quantile, quantileInto, random, random, randomInto, setRandomEngine, survival, survival, survival
-
Field Details
-
n
protected int n
-
-
Constructor Details
-
Kendall
public Kendall(int n)
-
-
Method Details
-
calculate_tau
public static final double calculate_tau(double x, int n) -
calculate_count
public static final double calculate_count(double tau, int n) -
density
public static final double density(double x, int n) Density of Kendall distribution- Parameters:
x- This is count, not tau!n-- Returns:
- density
-
density_tau
public static final double density_tau(double tau, int n) Density of Kendall distribution- Parameters:
tau- This is tau, not count!n-- Returns:
- density
-
cumulative
public static final double cumulative(double x, int n) Cumulative density function of Kendall distribution.Kendall statistics: x = round((rho + 1) * n * (n-1) / 4);
Two-sided test: min(1, 2*((q > n*(n-1)/4) ? 1-cumulative(x-1,n) : cumulative(x,n)));
Greater test: 1-cumulative(x-1,n)
Less test: cumulative(x,n)
- Parameters:
x- This is count, not tau!n-- Returns:
- cumulative
-
cumulative_tau
public static final double cumulative_tau(double tau, int n) Cumulative distribution of Kendall distribution- Parameters:
tau- This is tau, not count!n-- Returns:
- cumulative
-
quantile
public static final double quantile(double p, int n) Quantile search.- Parameters:
p-n-- Returns:
- count
-
quantile_tau
public static final double quantile_tau(double p, int n) -
random
Kendall RNG by inversion- Parameters:
n-random-- Returns:
- random variate
-
random
-
density
public double density(double x, boolean log) - Specified by:
densityin classGenericDistribution
-
cumulative
public double cumulative(double p, boolean lower_tail, boolean log_p) - Specified by:
cumulativein classGenericDistribution
-
quantile
public double quantile(double q, boolean lower_tail, boolean log_p) - Specified by:
quantilein classGenericDistribution
-
random
public double random()- Specified by:
randomin classGenericDistribution
-