# Example from Table 1 (p.4) of Yu and Cheng (2020):
ip <- itempool(a = c(0.976, 0.973, 0.871, 0.768, 0.94, 1.109, 1.063, 0.888,
0.648, 0.733, 0.8, 0.823, 0.611, 0.965, 1.052, 0.937,
0.894, 0.72, 0.686, 0.608),
b = c(-0.693, 0.6, -0.607, -0.637, -1.095, -0.202, -0.679,
0.058, -0.822, -0.768, -0.737, -1.158, -0.294, -0.856,
-0.833, -0.613, -0.151, -0.614, -0.07, -0.806),
c = c(0.371, 0.224, 0.159, 0.377, 0.159, 0.146, 0.181, 0.251,
0.179, 0.214, 0.312, 0.224, 0.246, 0.225, 0.155, 0.166,
0.456, 0.327, 0.112, 0.169),
D = 1.7)
resp <- c(0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 1)
theta <- -0.06
cusum_single(ip, resp, theta, method = "T5")
Run the code above in your browser using DataLab