fit_slogis_xpower | R Documentation |
Functions for fitting and sampling from SLxP distribution
Calculate QF, QDF, DQF qslogis_xpower
, fslogis_xpower
, dqslogis_xpower
for the SLxP-QPD
fit_slogis_xpower(p, q, log.p = FALSE, tol = .Machine$double.eps^2)
approx_slogis_xpower(
q,
nterms = 3L,
p = NULL,
thin = FALSE,
n_grid = 1000,
s_grid = 2L,
tol = .Machine$double.eps^2
)
qslogis_xpower(u, a)
fslogis_xpower(u, a, log = FALSE)
dqslogis_xpower(u, a, log = FALSE)
rslogis_xpower(n, a)
p |
the grid of probability values the quantiles q correspond to. This would be specified if metalog is fitted to the empirical CDF. Default is NULL. |
q |
vector of quantile values (data) |
log.p |
are probabilities provided on log scale. Default FALSE |
tol |
tolerance for solve() and qr.solve(), default is .Machine$double.eps^2 |
nterms |
integer number of terms for approximating metalog. Default is 3 |
thin |
logical. Should original data be thinned. Default is FALSE. |
n_grid |
in case data thinning is performed, integer number of quantiles to extract from data, if data vector |
s_grid |
in case data thinning is performed, probability grid shape parameter passed to |
u |
numeric probability |
a |
numeric vector of SLxP-QPD parameters. |
log |
logical, should the result be returned as a log. Default is FALSE |
n |
number of samples to draw |
fit_slogis_xpower
is for fitting the SLxP function to the set of QP values.
Number of SLxP terms will match the number of QP pairs.
approx_slogis_xpower
is for approximating SLxP function to the set of data.
is_slogis_xpower_valid
is a function for checking if the SLxP is valid
returns QF (qslogis_xpower
), QDF (fslogis_xpower
), DQF (dqslogis_xpower
) or random variate of skew-logistic distribution
p <- c(0.1, 0.5, 0.9)
q <- c(4, 9, 12)
a <-fit_slogis_xpower(p,q)
p_grd <- make_pgrid()
fslogis_xpower(p_grd, a)
dqslogis_xpower(p_grd, a)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.