sl: Significance Level for Changepoint

Description Usage Arguments Details Value Note Examples

Description

Significance level of a postulate value for the changepoint's x-coordinate or (x,y)-coordinates.

Usage

1
2
3
## S4 method for signature 'Cblmr'
sl( theta0,  method ="clr", accuracy =0.001, output =TRUE )
sl( theta0, alpha0,  method ="clr", accuracy =0.001, output =TRUE )

Arguments

theta0

postulate value for theta, the changepoint's x-coordinate

alpha0

postulate value for alpha, the changepoint's y-coordinate

method

"clr", "mc" or "af" which stand for conditional likelihood-ratio, conditional likelihood-ratio by Monte Carlo, or approximate-F, details below

accuracy

maximum absolute error in numerical integration by the "clr" method, or in Monte Carlo evaluation by the "mc" method, has no effect for the "af" method

output

TRUE or FALSE

Details

The default evaluation method "clr" evaluates the conditional likelihood-ratio significance level using a geometric-expectation formula derived by Siegmund-Zhang, which slightly over-estimates.

Method "mc" evaluates the conditonal likelihood-ratio significance level by direct Monte Carlo simulation, which avoids the over-estimate of the "clr" method.

Method "af" evaluates significance level by estimating the distribution of the likelihood-ratio statistic from the related F-distribution (or chi-squared distribution if variance is known) that would be exact if the model were linear. This method is not exact. It is common in nonlinear regression.

Value

Returns the numerical significance level if 'output' is set explicitly to TRUE or FALSE, otherwise only prints the result.

Note

The 'accuracy' argument does not include the slight over-estimate that is inherent in the "clr" method, nor the approximation inherent in the Approximate-F method.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
##  Data for Patient B from Smith and Cook (1980):
y = c(37.3, 47.1, 51.5, 67.6, 75.9, 73.3, 69.4, 61.5, 31.8, 19.4)
x = 1:10
sc <- blmr(y,x)

sc$sl(6.1)
sc$sl(6.1,"af")
sc$sl(6.1,"mc",0.00001)
tmp <- sc$sl(6.1,"clr",0.001,FALSE)
tmp

sc$sl(6.1,88.2)
sc$sl(6.1,88.2,"clr",0.00001)
sc$sl(6.1,88.2,"af")
sc$sl(6.1,88.2,"mc",0.00001)
tmp2 <- sc$sl(6.1,88.2,"af",.001,TRUE)
tmp2

blmr documentation built on May 2, 2019, 6:36 p.m.

Related to sl in blmr...