coef.intReg: Extract (only informative) coefficients, standard errors, and...

Description Usage Arguments Value Author(s) See Also Examples

Description

Internally, the interval boundaries are treated as fixed parameters. These methods extract only the informative ones (by default), i.e. they do not return the interval boundaries.

Usage

1
2
3
4
5
6
7
8
## S3 method for class 'intReg'
coef(object, boundaries = FALSE, ...)
## S3 method for class 'intReg'
stdEr(x, boundaries = FALSE, ...)
## S3 method for class 'intReg'
summary(object, boundaries = FALSE, ...)
## S3 method for class 'intReg'
vcov(object, boundaries = FALSE, ...)

Arguments

object,x

object of class ‘intReg’, estimated interval regression model

boundaries

logical, whether to return (fixed) interval boundary parameters

...

arguments for other methods

Value

a named numeric vector or matrix, for the estimated coefficients and standard errors, and variance-covariance matrix respectively.

Author(s)

Ott Toomet otoomet@gmail.com

See Also

summary.intReg which provides related functionality.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## Example of observation-specific boundaries
## 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), 400),]
                        # 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(coef(m))
print(coef(m, boundaries=TRUE))
print(nObs(m))

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