x <- seq(0.1, 1, 0.1)
dchen.exp(x, 1.5, 0.8, 2)
pchen.exp(x, 1.5, 0.8, 2)
qchen.exp(0.5, 1.5, 0.8, 2)
rchen.exp(10, 1.5, 0.8, 2)
hchen.exp(x, 1.5, 0.8, 2)
#Data
x <- stress
#ML Estimates
params = list(alpha=2.5462, beta=0.0537, lambda=87.6028)
#P–P (probability–probability) plot
pp.plot(x, params = params, pfun = pchen.exp, fit.line=TRUE)
#Q-Q (quantile–quantile) plot
qq.plot(x, params = params, qfun = qchen.exp, fit.line=TRUE)
# Goodness-of-Fit(GoF) and Model Diagnostics
# Display plot; numerical summary stored in 'out'
out <- gofic(x, params = params, dfun = dchen.exp,
pfun = pchen.exp, plot=TRUE)
print.gofic(out)
Run the code above in your browser using DataLab