## Dummy example
## Create dataset
set.seed(10)
x<-rnorm(200,3,2)
y<-3*x+rnorm(200)
dat<-data.frame(y,x)
## Fit FKML GLD regression with 3 simulations
fit<-GLD.lm.full(y~x,data=dat,fun=fun.RMFMKL.ml.m,param="fkml",n.simu=3)
## Note this is for illustration only, need to set number
## of simulations around 1000 usually for the graphics below
## to be meaningful
summaryGraphics.gld.lm(fit,ColourVersion=FALSE,diagnostic=FALSE)
if (FALSE) {
## Extract the Engel dataset
library(quantreg)
data(engel)
## Fit a full GLD regression
engel.fit.full<-GLD.lm.full(foodexp~income,data=engel,param="fmkl",
fun=fun.RMFMKL.ml.m)
## Plot coefficient summary
summaryGraphics.gld.lm(engel.fit.full,ColourVersion=FALSE,diagnostic=FALSE)
summaryGraphics.gld.lm(engel.fit.full)
## Extract the mammals dataset
library(MASS)
## Fit a full GLD regression
mammals.fit.full<-GLD.lm.full(log(brain)~log(body),data=mammals,param="fmkl",
fun=fun.RMFMKL.ml.m)
## Plot coefficient summary
summaryGraphics.gld.lm(mammals.fit.full,label=c("intercept","log of body weight"))
}
Run the code above in your browser using DataLab