Description Usage Arguments Details Value Author(s) References See Also Examples
Density, distribution function, quantile function and random generation for the 4-parameter two piece distribution with 3 parameterizations: two-piece (tp), epsilon-skew (eps), and inverse scale factors (isf).
1 2 3 4 |
x |
vector of quantiles. |
p |
vector of probabilities. |
n |
number of observations. If |
mu |
location parameter, mu. |
par1 |
scale parameter 1, par1. |
par2 |
scale parameter 2, par2. |
delta |
shape parameter, delta. |
FUN |
a symmetric density |
param |
parameterizations used. |
log, log.p |
logical; if TRUE, probabilities p are given as log(p). |
The 4-parameter two piece distribution with parameters mu, par1, par2 and delta has the following density:
s(x) = ( 2/(par1 + par2) ) f( (x - mu)/par1, delta ) for x < mu
and
s(x) = ( 2/(par1 + par2) ) f( (x - mu)/par2, delta ) for x >= mu
where f(x,delta)
is a symmetric density about zero.
More details
If param is not specified, it assumes the default value of "tp". Information about the "eps" and "isf" parameterizations can be found in the References.
dtp4
gives the density, ptp4
gives the distribution function, qtp4
gives the quantile function and rtp4
generates random deviates.
F. J. Rubio fxrubio@gmail.com and A. M. López amonteslop@gmail.com.
Arellano-Valle, R. B Gómez, H. W. and Quintana, F. A. (2005). Statistical inference for general class of asymmetric distributions. Journal of Statistical Planning and Inference, 128: 427-443.
Fernández, C. and Steel, M. F. J. (1998). On Bayesian modeling of fat tails and skewness. Journal of the American Statistical Asociation, 93, 359-371.
Mudholkar, G. S. and Hutson, A. D. (2000). The epsilon-skew-normal distribution for analyzing near-normal data. Journal of Statistical Planning and Inference, 83: 291-309.
Rubio, F. J. and Steel, M. F. J. (2014). Inference in Two-Piece Location-Scale models with Jeffreys Priors, with discussion. Bayesian Analysis, 9: 1-22.
dnorm for the normal distribution and dt for the Student t distribution.
dtp3
for the 3-parameter two piece distribution.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | ## 4-parameter two piece Student-t density with parameterization 'tp'
tempf = function(x) dtp4(x,0,3,1,4,dt,param="tp")
curve(tempf,-10,5)
## 4-parameter two piece Student-t distribution with parameterization 'tp'
tempf = function(x) ptp4(x,0,3,1,4,pt,param="tp")
curve(tempf,-10,5)
## random number generation for 4-parameter two piece Student-t distribution
## with parameterization 'tp'
sim <- rtp4(1000,0,1,1,10,rt)
hist(sim, probability=TRUE, xlim=c(-10,10),ylim=c(0,dt(0,4)))
## quantile function for the 4-parameter two piece Student-t distribution
## with parameterization 'tp'
qtp4(0.5, 0, 1, 1, 4, qt ,param = "tp")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.