View source: R/BE3.backward.crit.R
BE3.backward | R Documentation |
BE3.backward.crit implements the covariates selection based on backward and the Akaike's information criteria (AIC). BE3.backward.sign implements the covariates selection based on backward and significance of the covariates.
BE3.backward.crit(data, tau = 0.5, link.mu = "logit")
data |
a list containing the response vector ( |
tau |
the quantile of the distribution to be modelled ( |
link.mu |
link function to be used for |
A list containg the covariates to be included for modelling \mu
, \alpha
and \beta
, respectively.
Diego Gallardo and Marcelo Bourguignon.
##Simulating two covariates
set.seed(2100)
x1<-rnorm(200); x2<-rbinom(200, size=1, prob=0.5)
##Desing matrices: Z1 includes x1 and x2,
##Z2 includes only x1 and Z3 includes only x2
Z1=model.matrix(~x1+x2);Z2=model.matrix(~x1);Z3=model.matrix(~x2)
##Fixing parameters
theta=c(1, 0.2, -0.5); nu=c(0.5,-0.2); eta=c(-0.5, 0.3); tau=0.4
mu=plogis(Z1%*%theta); alpha=exp(Z2%*%nu); beta=exp(Z3%*%eta)
y=rBE3(200, mu, alpha, beta, tau=tau)
data=list(y=y, Z1=Z1, Z2=Z2, Z3=Z3)
BE3.backward.crit(data, tau = tau)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.