ks.expo.weibull: Test of Kolmogorov-Smirnov for the Exponentiated Weibull(EW)...

Description Usage Arguments Details Value References See Also Examples

View source: R/ExpoWeibull.R

Description

The function ks.expo.weibull() gives the values for the KS test assuming a Exponentiated Weibull(EW) with shape parameter alpha and scale parameter theta. In addition, optionally, this function allows one to show a comparative graph between the empirical and theoretical cdfs for a specified data set.

Usage

1
2
ks.expo.weibull(x, alpha.est, theta.est, 
    alternative = c("less", "two.sided", "greater"), plot = FALSE, ...)

Arguments

x

vector of observations.

alpha.est

estimate of the parameter alpha

theta.est

estimate of the parameter theta

alternative

indicates the alternative hypothesis and must be one of "two.sided" (default), "less", or "greater".

plot

Logical; if TRUE, the cdf plot is provided.

...

additional arguments to be passed to the underlying plot function.

Details

The Kolmogorov-Smirnov test is a goodness-of-fit technique based on the maximum distance between the empirical and theoretical cdfs.

Value

The function ks.expo.weibull() carries out the KS test for the Exponentiated Weibull(EW)

References

Mudholkar, G.S. and Srivastava, D.K. (1993). Exponentiated Weibull family for analyzing bathtub failure-rate data, IEEE Transactions on Reliability, 42(2), 299-302.

Murthy, D.N.P., Xie, M. and Jiang, R. (2003). Weibull Models, Wiley, New York.

Nassar, M.M., and Eissa, F. H. (2003). On the Exponentiated Weibull Distribution, Communications in Statistics - Theory and Methods, 32(7), 1317-1336.

See Also

pp.expo.weibull for PP plot and qq.expo.weibull for QQ plot

Examples

1
2
3
4
5
6
7
## Load data sets
data(stress)
## Maximum Likelihood(ML) Estimates of alpha & theta for the data(stress)
## Estimates of alpha & theta using 'maxLik' package
## alpha.est =1.026465, theta.est = 7.824943

ks.expo.weibull(stress, 1.026465, 7.824943, alternative = "two.sided", plot = TRUE)

Example output

	One-sample Kolmogorov-Smirnov test

data:  x
D = 0.11592, p-value = 0.136
alternative hypothesis: two-sided

Warning message:
In ks.test(x, pexpo.weibull, alpha, theta, alternative = alternative) :
  ties should not be present for the Kolmogorov-Smirnov test

reliaR documentation built on May 1, 2019, 9:51 p.m.