Description Usage Arguments Details Value Author(s) References See Also Examples
frm.ggoff
is used to test the specification of fractional regression models.
1 |
object |
an object containing the results of an |
version |
a vector containing the test versions to use. Available options: |
table |
a logical value indicating whether a summary table with the test results should be printed. |
... |
Arguments to pass to glm, which is used to estimate the model under the alternative hypothesis when
|
frm.ggoff
applies the GGOFF, GOFF1 and GOOFF2 test statistics to fractional regression
models estimated via frm
. frm.ggoff
may be used to test the link
specification of: (i) one-part fractional regression models; (ii) the binary
component of two-part fractional regression models; and (iii) the fractional
component of two-part fractional regression models. When the Wald
version is implemented, it is taken into account the option that was chosen for
computing standard errors in the model under evaluation. For the LM
version,
a robust version is computed in cases (i) and (iii) and a conventional version in
case (ii). See Ramalho, Ramalho and Murteira (2014) for details on the application of the
GGOFF, GOFF1 and GOOFF2 tests in the fractional regression framework.
frm.ggoff
returns a named vector with the test results.
Joaquim J.S. Ramalho <jsr@uevora.pt>
Ramalho, E.A., J.J.S. Ramalho and J.M.R. Murteira (2014), "A generalized goodness-of-functional form test for binary and fractional regression models", Manchester School, 82(4), 488-507.
frm
, for fitting fractional regression models.
frm.reset
, for asymptotically equivalent specification tests.
frm.ptest
, for non-nested hypothesis tests.
frm.pe
, for computing partial effects.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | N <- 250
u <- rnorm(N)
X <- cbind(rnorm(N),rnorm(N))
dimnames(X)[[2]] <- c("X1","X2")
ym <- exp(X[,1]+X[,2]+u)/(1+exp(X[,1]+X[,2]+u))
y <- rbeta(N,ym*20,20*(1-ym))
y[y > 0.9] <- 1
#Testing the logit specification of a standard fractional regression model
#using LM and Wald versions of the GGOFF test, based on 1 or 2 fitted powers of
#the linear predictor
res <- frm(y,X,linkfrac="logit",table=FALSE)
frm.ggoff(res,c("Wald","LM"))
#Testing the probit specification of the binary component of a two-part fractional
#regression model using a LR-based GGOFF test
res <- frm(y,X,linkbin="probit",type="2Pbin",inf=1,table=FALSE)
frm.ggoff(res,"LR")
## See the website http://evunix.uevora.pt/~jsr/FRM.htm for more examples.
|
*** GGOFF test ***
H0: Fractional logit model
Test Version Statistic p-value
GOFF1 LM 0.005 0.943
GOFF1 Wald 0.005 0.943
GOFF2 LM 0.070 0.792
GOFF2 Wald 0.068 0.794
GGOFF LM 0.626 0.731
GGOFF Wald 0.507 0.776
*** GGOFF test ***
H0: Binary probit component of a two-part model
Test Version Statistic p-value
GOFF1 LR 0.219 0.640
GOFF2 LR 0.708 0.400
GGOFF LR 4.205 0.122
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.