Package com.opttek.optquest
Class COptQuestTDistribution
java.lang.Object
com.opttek.optquest.COptQuestTDistribution
- All Implemented Interfaces:
com.opttek.optquest.IProbabilityDistribution
public class COptQuestTDistribution
extends Object
implements com.opttek.optquest.IProbabilityDistribution
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoublecdf(double x) static doubleCDF(double t, double df) Student's t-Distribution Cumulative Distribution Function (CDF) Computes P(T ≤ t) where T follows a t-distribution with df degrees of freedom.doublechaz(double x) doublehaz(double x) doublepdf(double x) static doublePDF(double t, double df) Student's t-Distribution Probability Density Function (PDF) Computes the probability density at t for a t-distribution with df degrees of freedom.doubleppf(double x) static doublePPF(double p, double df) Student's t-Distribution Percent Point Function (PPF) - Inverse CDF Computes the value t such that P(T ≤ t) = p, where T follows a t-distribution with df degrees of freedom.doublesf(double x)
-
Constructor Details
-
COptQuestTDistribution
public COptQuestTDistribution(double df)
-
-
Method Details
-
pdf
public double pdf(double x) - Specified by:
pdfin interfacecom.opttek.optquest.IProbabilityDistribution
-
cdf
public double cdf(double x) - Specified by:
cdfin interfacecom.opttek.optquest.IProbabilityDistribution
-
ppf
public double ppf(double x) - Specified by:
ppfin interfacecom.opttek.optquest.IProbabilityDistribution
-
sf
public double sf(double x) - Specified by:
sfin interfacecom.opttek.optquest.IProbabilityDistribution
-
chaz
public double chaz(double x) - Specified by:
chazin interfacecom.opttek.optquest.IProbabilityDistribution
-
haz
public double haz(double x) - Specified by:
hazin interfacecom.opttek.optquest.IProbabilityDistribution
-
CDF
public static double CDF(double t, double df) Student's t-Distribution Cumulative Distribution Function (CDF) Computes P(T ≤ t) where T follows a t-distribution with df degrees of freedom. Uses the relationship: CDF(t, df) = 0.5 * I_x(df/2, 1/2) where I_x is the regularized incomplete beta function and x = df/(df + t²).- Parameters:
t- the value at which to evaluate the CDFdf- degrees of freedom (must be positive)- Returns:
- the cumulative probability P(T ≤ t)
-
PDF
public static double PDF(double t, double df) Student's t-Distribution Probability Density Function (PDF) Computes the probability density at t for a t-distribution with df degrees of freedom. Formula: f(t; ν) = Γ((ν+1)/2) / (√(νπ) * Γ(ν/2)) * (1 + t²/ν)^(-(ν+1)/2)- Parameters:
t- the value at which to evaluate the PDFdf- degrees of freedom (must be positive)- Returns:
- the probability density at t
-
PPF
public static double PPF(double p, double df) Student's t-Distribution Percent Point Function (PPF) - Inverse CDF Computes the value t such that P(T ≤ t) = p, where T follows a t-distribution with df degrees of freedom. Uses normal approximation for initial guess when df > 1000, then applies Newton-Raphson iteration for refinement.- Parameters:
p- the probability (must be between 0 and 1, exclusive)df- degrees of freedom (must be positive)- Returns:
- the value t such that CDF(t, df) = p
-