DPmain: Main function of DP approach

Description Usage Arguments Author(s) References Examples

Description

Main function of DP approach

Usage

1
DPmain(x, y, K)

Arguments

x

input data x

y

input data y

K

given number of change-points

Author(s)

Bingwen Zhang

References

Bingwen Zhang, Jun Geng and Lifeng Lai, Detecting changes in regression models via sparse group lasso, http://users.wpi.edu/~bzhang/icassp_v1.pdf

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function (x, y, K) 
{
    n <- dim(x)[1]
    p <- dim(x)[2]
    c1 <- computeC(x, y, n, p)
    sol <- DPSol(x, y, n, p, K + 1, c1)
    predictedAlpha <- PrintAlpha(x, y, sol)
    return(list(Sol = sol, AlphaHat <- predictedAlpha))
  }

boris109able/ChangePointCalc documentation built on May 13, 2019, 12:34 a.m.