cf_LogRV_FisherSnedecor: Characteristic function of a linear combination of...

View source: R/cf_LogRV_FisherSnedecor.R

cf_LogRV_FisherSnedecorR Documentation

Characteristic function of a linear combination of independent LOG-TRANSFORMED FISHER-SNEDECOR F random variables

Description

cf_LogRV_FisherSnedecor(t, df1, df2, coef, niid) evaluates characteristic function of a linear combination (resp. convolution) of independent LOG-TRANSFORMED FISHER-SNEDECOR F random variables (RVs) log(X), where X ~ F(df1,df2) has the FISHER-SNEDECOR F distribution with df1 > 0 and df2 > 0 degrees of freedom.

That is, cf_LogRV_FisherSnedecor evaluates the characteristic function cf(t) of Y = coef_1*log(X_1) +...+ coef_N*log(X_N), where X_i ~ F(df1_i,df2_i), with degrees of freedom df1_i and df2_i, for i = 1,...,N.

The characteristic function of Y = log(X), with X ~ F(df1,df2,\lambda), where \lambda is the non-centrality parameter, is defined by cf_Y(t) = E(exp(1i*t*Y)) = E(exp(1i*t*log(X))) = E(X^(1i*t)). That is, the characteristic function can be derived from expression for the r-th moment of X, E(X^r) by using (1i*t) instead of r. In particular, the characteristic function of Y = log(X) is defined by

cf_Y(t) = (df2/df1)^(1i*t) * gamma(df1/2 + 1i*t) / gamma(df1/2) * gamma(df2/2 - 1i*t) / gamma(df2/2).

Hence,the characteristic function of Y = coef(1)*Y1 + ... + coef(N)*YN is

cf_Y(t) = cf_Y1(coef(1)*t) * ... * cf_YN(coef(N)*t),

where cf_Yi(t) is evaluated with the parameters df1(i), df2(i), and \lambda(i).

Usage

cf_LogRV_FisherSnedecor(t, df1, df2, coef, niid)

Arguments

t

vector or array of real values, where the CF is evaluated.

df1

vector of the degrees of freedom df1 > 0. If empty, default value is df1 = 1.

df2

vector of the degrees of freedom df2 > 0. If empty, default value is df2 = 1.

coef

vector of the coefficients of the linear combination of the Beta distributed random variables. If coef is scalar, it is assumed that all coefficients are equal. If empty, default value is coef = 1.

niid

scalar convolution coeficient niid, such that Z = Y + ... + Y is sum of niid iid random variables Y, where each Y = sum_{i=1}^N coef(i) * log(X_i) is independently and identically distributed random variable. If empty, default value is niid = 1.

Value

Characteristic function cf(t) of a linear combination of independent LOG-TRANSFORMED FISHER-SNEDECOR F random variables.

Note

Ver.: 20-Sep-2018 19:26:09 (consistent with Matlab CharFunTool v1.3.0, 10-Aug-2018 15:46:49).

See Also

For more details see WIKIPEDIA: https://en.wikipedia.org/wiki/F-distribution.

Other Continuous Probability Distribution: cfS_Arcsine(), cfS_Beta(), cfS_Gaussian(), cfS_Laplace(), cfS_Rectangular(), cfS_Student(), cfS_TSP(), cfS_Trapezoidal(), cfS_Triangular(), cfS_Wigner(), cfX_ChiSquare(), cfX_Exponential(), cfX_FisherSnedecor(), cfX_Gamma(), cfX_InverseGamma(), cfX_LogNormal(), cf_ArcsineSymmetric(), cf_BetaNC(), cf_BetaSymmetric(), cf_Beta(), cf_ChiSquare(), cf_Exponential(), cf_FisherSnedecorNC(), cf_FisherSnedecor(), cf_Gamma(), cf_InverseGamma(), cf_Laplace(), cf_LogRV_BetaNC(), cf_LogRV_Beta(), cf_LogRV_ChiSquareNC(), cf_LogRV_ChiSquare(), cf_LogRV_FisherSnedecorNC(), cf_LogRV_MeansRatioW(), cf_LogRV_MeansRatio(), cf_LogRV_WilksLambdaNC(), cf_LogRV_WilksLambda(), cf_Normal(), cf_RectangularSymmetric(), cf_Student(), cf_TSPSymmetric(), cf_TrapezoidalSymmetric(), cf_TriangularSymmetric(), cf_vonMises()

Examples

## EXAMPLE 1
# CF of a weighted linear combination of independent log-F RVs
coef <- c(1, 2, 3, 4, 5)
weight <- coef / sum(coef)
df1 <- 5
df2 <- 3
t <- seq(from = -10,
         to = 10,
         length.out = 201)
plotReIm(function(t)
        cf_LogRV_FisherSnedecor(t, df1, df2, weight),
        t,
        title = "Characteristic function of a linear combination of log-F RVs")

## EXAMPLE 2
# PDF/CDF from the CF by cf2DistGP
coef <- c(1, 2, 3, 4, 5)
weight <- coef / sum(coef)
df1 <- 5
df2 <- 3
cf <- function(t)
        cf_LogRV_FisherSnedecor(t, df1, df2, weight)
options <- list()
options$N <- 2 ^ 12
prob <- c(0.9, 0.95, 0.99)
result <- cf2DistGP(cf = cf, prob = prob, options = options)
str(result)

gajdosandrej/CharFunToolR documentation built on June 3, 2024, 7:46 p.m.