cr: Confidence Region for the Changepoint

Description Usage Arguments Details Value Examples

Description

Joint confidence region for ( theta, alpha ), the changepoint's (x,y)-coordinates.

Usage

1
2
## S4 method for signature 'Cpp_Clmbr'
cr(  CL =0.95 ,  method ="CLR",  incr,  output ="G"  )

Arguments

CL

confidence level, between 0 and 1.

method

"CLR" or "AF" which stand for conditional likelihood-ratio or approximate-F (rapid), see sl for details.

incr

increment of theta values for the confidence region's boundary-points.

output

"G", "T" or "V" which stand for graph, text or value.

Details

This subroutine scans to determine the postulate values of (theta, alpha) that have significance level greater than 1-CL. It scans first along the (theta, alpha-MLE) ridge to determine the 'theta' boundary limits.

Value

If 'output' is "G" or "T" then 'cr' graphs or prints-out the confidence region but does not return a value. If 'output' is "V" then 'cr' returns an N x 3 matrix of boundary points ( theta, min-alpha, max-alpha ).

Examples

1
2
3
4
5
6
#  A quick example
y <- c( 2, 0, 2.001, 4, 6 )
x <- 1:5
t <- lm.br( y ~ x )
t $ cr()
t$cr( .9, 'af', incr = 0.1, out='t' )

Example output

Loading required package: Rcpp
 lm.br  version 2.9.3,  '?lm.br' starts help
   getting theta-boundaries...   
   getting alpha-boundaries...   

90-percent joint confidence region for  (theta, alpha)  by AF

     theta      min. alpha     max. alpha

         1,      -1.99948,      -1.99948
   1.00001,      -2.00968,      -1.98928
       1.1,      -1.80937,      -1.78965
       1.2,      -1.60904,         -1.59
       1.3,      -1.40872,      -1.39034
       1.4,       -1.2084,      -1.19068
       1.5,      -1.00808,      -0.99102
       1.6,     -0.807767,     -0.791353
       1.7,     -0.607459,     -0.591681
       1.8,     -0.407155,     -0.392005
       1.9,     -0.206857,     -0.192323
         2,   -0.00656491,    0.00736491
   2.00391,   -0.00268575,   -0.00268575

lm.br documentation built on May 2, 2019, 9:59 a.m.

Related to cr in lm.br...