Package jdistlib
Class Zipf
java.lang.Object
jdistlib.generic.GenericDistribution
jdistlib.Zipf
Zipf distribution
Parts taken from VGAM
-
Field Summary
FieldsFields inherited from class jdistlib.generic.GenericDistribution
random -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoublecumulative(double p, boolean lower_tail, boolean log_p) static final doublecumulative(int x, int N, double s, boolean lower_tail, boolean log_p) doubledensity(double x, boolean log) static final doubledensity(int x, int N, double s, boolean give_log) doublequantile(double q, boolean lower_tail, boolean log_p) static final doublequantile(double p, int N, double s, boolean lower_tail, boolean log_p) doublerandom()static final doublerandom(int N, double s, RandomEngine random) static final double[]random(int n, int N, double s, RandomEngine random) Methods 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 -
s
protected double s
-
-
Constructor Details
-
Zipf
public Zipf(int N, double s)
-
-
Method Details
-
density
public static final double density(int x, int N, double s, boolean give_log) -
cumulative
public static final double cumulative(int x, int N, double s, boolean lower_tail, boolean log_p) -
quantile
public static final double quantile(double p, int N, double s, boolean lower_tail, boolean log_p) -
random
-
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
-