useDynLib("frailtypack", .registration = TRUE, .fixes = "C_")

export(frailtyPenal,additivePenal,hazard,survival,slope,cluster,subcluster,terminal,num.id,Cmeasures,SurvIC,event2,multivPenal,timedep,prediction,epoce,Diffepoce,longiPenal,trivPenal,trivPenalNL)

import("survival","boot","MASS","survC1","nlme")
importFrom("graphics", "abline", "legend", "lines", "matlines","matplot", "par", "plot")
importFrom("stats", ".getXlevels", "aggregate", "as.formula","complete.cases", 
		"contrasts", "get_all_vars","is.empty.model", "model.extract", 
		"model.matrix", "pchisq","pnorm", "qnorm", "quantile", 
		"rgamma", "terms", "update","var","model.frame","na.pass")
importFrom("utils", "flush.console")
importFrom(statmod, gauss.quad)
importFrom(nlme, lme)

S3method(plot,frailtyPenal)
S3method(lines,frailtyPenal)
S3method(plot,jointPenal)
S3method(plot,nestedPenal)
S3method(plot,additivePenal)
S3method(plot,jointNestedPenal)

S3method(print,additivePenal)
S3method(print,frailtyPenal)
S3method(print,jointPenal)
S3method(print,nestedPenal)
S3method(print,jointNestedPenal)

S3method(summary,additivePenal)
S3method(summary,frailtyPenal)
S3method(summary,jointPenal)
S3method(summary,nestedPenal)
S3method(summary,jointNestedPenal)

S3method(print,Cmeasures)

S3method(plot,predJoint)
S3method(print,predJoint)
S3method(print,predJointNested)
S3method(plot,predJointNested)
S3method(print,predFrailty)
S3method(plot,predFrailty)
S3method(print,predLongi)
S3method(plot,predLongi)

S3method(print,multivPenal)
S3method(summary,multivPenal)
S3method(plot,multivPenal)

S3method(print,epoce)
S3method(plot,epoce)
S3method(print,Diffepoce)
S3method(plot,Diffepoce)

S3method(print,longiPenal)
S3method(summary,longiPenal)
S3method(plot,longiPenal)

S3method(print,trivPenal)
S3method(summary,trivPenal)
S3method(plot,trivPenal)

S3method(print,trivPenalNL)
S3method(summary,trivPenalNL)
S3method(plot,trivPenalNL)