restriktor_methods: Methods for restriktor

Description Usage Arguments Details Value Examples

Description

restricted estimation and confidence intervals for (robust) linear (in)equality restricted hypotheses.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## S3 method for class 'restriktor'
print(x, digits = max(3, getOption("digits") - 2), ...)

## S3 method for class 'restriktor'
summary(object, bootCIs = TRUE, 
        bty = "perc", level = 0.95, goric = "goric", ...)

## S3 method for class 'summary.restriktor'
print(x, digits = max(3, getOption("digits") - 2),
              signif.stars = getOption("show.signif.stars"), ...)     

## S3 method for class 'restriktor'
coef(object, ...)

## S3 method for class 'restriktor'
model.matrix(object, ...)

## S3 method for class 'restriktor'
logLik(object, ...)
  

Arguments

object

an object of class restriktor.

x

an object of class restriktor.

bootCIs

if TRUE (default), nonparametric bootstrap confidence intervals are generated. Only available if object contains bootout object.

bty

a character string representing the type of interval required. The value should be any of the values "norm", "basic","perc","bca". The value "stud" is not supported. For more details see boot.ci.

level

the confidence level of the interval (default = 0.95).

goric

if "goric" (default), the generalized order-restricted information criterion value is computed. If "gorica" the log-likihood is computed using the multivariate normal distribution function. If "goricc" or "goricca", a small sample version of the "goric" or "gorica" is computed.

digits

the number of significant digits to use when printing.

signif.stars

If TRUE, "significance stars are printed for each coefficient.

...

no additional arguments for now.

Details

The function print returns the restricted coefficients. The output from the print.summary.conLM function provides information that is comparable with the output from print.summary.lm. Additional information is provided about the unrestricted and restricted R-square and by default the output of the GORIC. If bootstrapped standard errors are requested (e.g., option se = "boot.model.based" in the restriktor function and bootCI = TRUE in the summary function) standard errors and confidence intervals are provided.

Value

The function summary computes and returns a list of summary statistics of the fitted unrestricted and restricted (robust) linear model given in object, plus

se.type

type of standard error computed, equal to input se in the restriktor function.

residuals

the weighted residuals.

coefficients

a p x 4 matrix with columns for the estimated coefficient, its standard error, t-statistic and corresponding p-value. If bootCIs = TRUE and the bootout object is available in the object, bootstrapped standard errors and confidence intervals are produced.

rdf

residual degrees of freedom.

R2.org

unrestricted R-squared.

R2.reduced

restricted R-squared.

goric

goric value and attributed its penalty term and log-likelihood.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
  # unrestricted linear model for ages (in months) at which an 
  # infant starts to walk alone.
  
  # prepare data
  DATA <- subset(ZelazoKolb1972, Group != "Control")
  
  # fit unrestricted linear model
  fit.lm <- lm(Age ~ -1 + Group, data = DATA)
  
  # restricted linear model with restrictions that the walking 
  # exercises would not have a negative effect of increasing the 
  # mean age at which a child starts to walk. 
  fit.con <- restriktor(fit.lm, constraints = ' GroupActive  < GroupPassive; 
                                                GroupPassive < GroupNo ')
  
  summary(fit.con)

Example output

This is restriktor 0.1-70
restriktor is BETA software! Please report any bugs.

Call:
conLM.lm(object = fit.lm, constraints = " GroupActive  < GroupPassive; 
                                                GroupPassive < GroupNo ")

Restriktor: restricted linear model:

Residuals:
   Min     1Q Median     3Q    Max 
-1.375 -0.850 -0.375  0.375  3.625 

Coefficients:
             Estimate Std. Error t value  Pr(>|t|)    
GroupActive  10.12500    0.61854  16.369 1.594e-10 ***
GroupNo      12.35000    0.67757  18.227 3.771e-11 ***
GroupPassive 11.37500    0.61854  18.390 3.344e-11 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Residual standard error: 1.5151 on 14 degrees of freedom
Standard errors: standard 
Multiple R-squared remains 0.985 

Generalized Order-Restricted Information Criterion:
  Loglik  Penalty    Goric 
-29.5348   2.8418  64.7533 

restriktor documentation built on Feb. 25, 2020, 5:08 p.m.