###################################################################################
########### Fraction of Cell Volume Data - a Power-exponential model ###########
###################################################################################
data("Ovocytes", package="ssym")
fit <- ssym.l(fraction ~ type + psp(time) | type + psp(time), data=Ovocytes,
family='Powerexp', xi=-0.65, local.influence=TRUE)
summary(fit)
################## Plot of the non-parametric effects ##################
par(mfrow=c(1,2))
np.graph(fit, which=1)
np.graph(fit, which=2, exp=TRUE)
################## Plot of deviance-type residuals ##################
plot(fit)
################## Plot of local influence measures ##################
ilm <- influence.ssym(fit)
###################################################################################
################## Biaxial Fatigue Data - a Birnbaum-Saunders model #############
###################################################################################
data("Biaxial", package="ssym")
fit <- ssym.l(log(Life) ~ log(Work), family='Sinh-normal', xi=0.41, data=Biaxial,
local.influence=TRUE)
summary(fit)
################## Plot of the fitted model ##################
xl <- "Work per cycle"
rx <-range(Biaxial$Work)
ry <- range(Biaxial$Life)
plot(Biaxial$Work,Biaxial$Life,xlim=rx,ylim=ry,type="p",cex=0.3,lwd=3,ylab="",xlab="")
par(new=TRUE)
ids <- sort(Biaxial$Work, index=TRUE)$ix
plot(Biaxial$Work[ids],exp(fitted(fit)$mu[ids]),xlim=rx,ylim=ry,type="l",ylab="Life",xlab=xl)
################## Plot of deviance-type residuals ##################
plot(fit)
################## Plot of local influence measures ##################
ilm <- influence.ssym(fit)
Run the code above in your browser using DataLab