pdf.plot(obj = NULL, obs = c(1), family = NO(), mu = NULL,
sigma = NULL, nu = NULL, tau = NULL, min = NULL,
max = NULL, step = NULL, allinone = FALSE,
no.title = FALSE, ...)
obj=model1
where model1 is a fitted gamlss objectobs=c(23,58)
will display the fitted distribution for the 23th and 58th observationsfamily=NO
mu=c(3,7)
sigma=c(3,7)
nu=3
tau=5
min=0
max=10
step=0.5
no.title=FALSE
obj
is specified and it is a GAMLSS fitted object, then the fitted distribution of this model
at specified observation values (given by the second argument obs
) is plotted for a specified y-variable range (arguments
min
, max
, and step
).
If the first argument is not given then the family
argument has to be specified and the pdf is plotted at specified values of the parameters
mu
, sigma
, nu
, tau
. Again the range of the y-variable has to be given.gamlss
pdf.plot(family=BCT, min=1, max=20, step=.05, mu=10, sigma=0.15, nu=-1, tau=c(4,10,20,40) )
# now using an gamlss object
# library(gamlss)
#data(abdom)
#h<-gamlss(y~pb(x), sigma.formula=~pb(x), family=BCT, data=abdom) # fits
#pdf.plot(obj=h , obs=c(23,67), min=50, max=150, step=.5)
Run the code above in your browser using DataLab