useDynLib(chngpt, .registration = TRUE)

export(chngpt.test, plot.chngpt.test, chngptm, chngptm.xy, print.chngptm,  antoch.test, performance.unit.test, plot.chngptm)
export(sim.pastor, sim.my, sim.chngpt, lincomb, sim.hinge, hinge.test, double.hinge, plot.double.hinge, threshold.func, predictx, convert.coef) 

importFrom("methods", "hasArg")
importFrom(kyotil, '%.%', rbern, expit, keepWarnings, myprint, concatList, mysapply, "tXDX", "interpolate", "last", getFixedEf, abline.pt.slope, contain)
importFrom(MASS, mvrnorm)
import(survival)
importFrom("graphics", "abline", "plot", "axis", "lines", "par", "points", "hist")
importFrom("utils", "str", "capture.output")
importFrom("boot", "boot.ci", "boot")
importFrom("splines", "ns")
importFrom("stats", "as.formula", "coef", "complete.cases", "cov2cor", "cov",
             "deriv3", "glm", "logLik", "median", "model.frame",
             "model.matrix", "na.pass", "optim", "pchisq", "pnorm",
             "predict", "pt", "qt", "quantile", "rbeta", "rgamma",
             "rnorm", "runif", "update", "density", "dnorm", "qchisq", "qnorm",
             "smooth.spline", "vcov", "sigma", "resid", "lm.fit", "rbinom", "residuals","fitted")

S3method(coef, chngptm)
S3method(residuals,chngptm)
S3method(vcov, chngptm)
S3method(vcov, double.hinge)
S3method(summary,chngptm)
S3method(summary,double.hinge)
S3method(fitted,double.hinge)
S3method(residuals,double.hinge)
S3method(print,double.hinge)
S3method(print,chngptm)
S3method(print,summary.chngptm)
S3method(print,summary.double.hinge)
S3method(predict,chngptm)
S3method(getFixedEf,chngptm)

S3method(plot,chngpt.test)
S3method(plot,chngptm)
S3method(plot,double.hinge)
