intReg-package: Interval Regression

Description Details Author(s) Examples

Description

This package estimates interval regression. Different disturbance distributions are supported and methods for predicting different outcomes are included.

Details

Interval regression is a linear regression model where the outcome variable is only observable in intervals. Assume y* is the latent outcome variable (link). Instead of y* we observe

y = (l, y) where l <= y < y.

l and u are the lower and upper boundaries, and we know that between lies between those. Note that in case l=y, we have a point observation.

If y* is related to the explanatory variables x as in the ordinary linear model

y* = β'x + ε,

the parameters β can be estimated by Maximum Likelihood.

Unlike the ordinary linear regression, there are more values one can predict in interval regression. intReg supports predicting:

As y*, one cannot compute the ordinary residuals. Instead, residuals reports generalized residuals, the expected difference between the predicted (conditional on x and the observed interval) and actual link E[predicted y* - y*|l <= y* < u, x].

Interval Regression shares similarities with several other censored linear model. Probit (and logit) are essentially interval regression models with only two observed intervals, (-Inf, 0) and [0, Inf). Ordered regression is a form of interval regression where the interval boundaries are unobserved and must be estimated. Finally, ordinary linear regression is an interval regression where all observations are point observations.

The central function of the package is intReg that estimates the model. It includes methods for coef, summary, predict, and others.

Author(s)

Ott Toomet <otoomet@gmail.com>, with original source adapted from R core team.

Maintainer: Ott Toomet <otoomet@gmail.com>

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## Estimate the willingness to pay for the Kakadu National Park
## Data given in intervals -- 'lower' for lower bound and 'upper' for upper bound.
## Note that dichotomous-coice answers are already coded to 'lower' and 'upper'
data(Kakadu, package="Ecdat")
set.seed(1)
Kakadu <- Kakadu[sample(nrow(Kakadu), 500),]
                        # subsample to speed up the estimation
## Estimate in log form, change 999 to Inf
lb <- log(Kakadu$lower)
ub <- Kakadu$upper
ub[ub > 998] <- Inf
ub <- log(ub)
y <- cbind(lb, ub)
m <- intReg(y ~ sex + log(income) + age + schooling + 
              recparks + jobs + lowrisk + wildlife + future + aboriginal + finben +
              mineparks + moreparks + gov +
              envcon + vparks + tvenv + major, data=Kakadu)
## You may want to compare the results to Werner (1999),
## Journal of Business and Economics Statistics 17(4), pp 479-486
print(summary(m))

Example output

Loading required package: miscTools
Loading required package: maxLik

Please cite the 'maxLik' package as:
Henningsen, Arne and Toomet, Ott (2011). maxLik: A package for maximum likelihood estimation in R. Computational Statistics 26(3), 443-458. DOI 10.1007/s00180-010-0217-1.

If you have questions, suggestions, or comments regarding the 'maxLik' package, please use a forum or 'tracker' at maxLik's R-Forge site:
https://r-forge.r-project.org/projects/maxlik/
--------------------------------------------
Interval regression
Maximum Likelihood estimation
BHHH maximisation, 10 iterations
Return code 2: successive function values within tolerance limit
Log-Likelihood: -388.4076 
500 observations, 20 free parameters (df = 480)
            Estimate Std. Error t value Pr(>|t|)    
(Intercept)  6.15184    2.45620   2.505 0.012589 *  
sexmale     -0.29115    0.42520  -0.685 0.493846    
log(income)  0.27120    0.26269   1.032 0.302420    
age         -0.04027    0.01210  -3.327 0.000944 ***
schooling   -0.08597    0.11507  -0.747 0.455360    
recparks     0.02805    0.17717   0.158 0.874289    
jobs        -0.58741    0.17699  -3.319 0.000972 ***
lowrisk     -0.82210    0.17765  -4.628 4.77e-06 ***
wildlife     0.25476    0.28975   0.879 0.379713    
future       0.05356    0.23680   0.226 0.821153    
aboriginal   0.12433    0.17646   0.705 0.481396    
finben      -0.43784    0.17458  -2.508 0.012471 *  
mineparks    0.55647    0.16470   3.379 0.000788 ***
moreparks    0.46348    0.17511   2.647 0.008392 ** 
gov         -1.28939    0.80773  -1.596 0.111076    
envconyes    0.16045    0.40575   0.395 0.692690    
vparksyes    0.21119    0.42780   0.494 0.621760    
tvenv       -0.13962    0.15103  -0.924 0.355730    
majoryes     0.63731    0.38715   1.646 0.100386    
sigma        2.93924    0.29179  10.073  < 2e-16 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
--------------------------------------------

intReg documentation built on May 2, 2019, 4:43 p.m.