# non-base package imports:

importFrom("grDevices", 
           "contourLines", 
           "rainbow", 
           "terrain.colors",
           "trans3d")

importFrom("stats", 
           "anova", 
           "as.formula", 
           "coef", 
           "delete.response",
           "formula", 
           "lm", 
           "model.frame", 
           "model.matrix", 
           "na.pass",
           "p.adjust",
           "p.adjust.methods",
           "pf",
           "predict", 
           "printCoefmat", 
           "reformulate",
           "rnorm", 
           "runif", 
           "sd", 
           "terms",
           "uniroot",
           "update",
           "weights")
     
import(graphics)


# Methods

S3method(print, coded.data)
S3method(print, summary.rsm)
S3method(summary, rsm)
S3method("[", coded.data)
S3method(codings, coded.data)
S3method(codings, rsm)
S3method("names<-", coded.data)
S3method(truenames, coded.data)
S3method("truenames<-", coded.data)

S3method(contour, lm)
S3method(image, lm)
S3method(persp, lm)

# emmeans support
# if (requireNamespace("emmeans", quietly = TRUE)) {
#     importFrom("emmeans", "recover_data", "emm_basis")
#     importFrom("estimability", "all.estble", "nonest.basis")
#     S3method(recover_data, rsm)
#     S3method(emm_basis, rsm)
# }
# emmeans support -- 
# See zzz.R where we dynamically register these methods
# export (recover_data.rsm, emm_basis.rsm)

# lsmeans support -- important thing is not to import lsmeans stuff,
# export (recover.data.rsm, lsm.basis.rsm)


# Exports

### exportPattern("^[[:alpha:]]+") - using explicit exports below
#--- export all that don't start with "."
#exportPattern("^[^\\.]")

# --- to make Ulrike's life easier...
#export(.ccd.1.41, .bbd.1.41)

export(
#       ".bbd.1.41", 
#       ".ccd.1.41", 
#       "[.coded.data", 
       "as.coded.data", 
       "bbd", 
       "canonical", 
       "canonical.path", 
       "ccd", 
       "ccd.pick", 
       "ChemReact", 
       "ChemReact1", 
       "ChemReact2", 
       "codata", 
       "code2val", 
       "coded.data", 
       "codings", 
#       "codings.coded.data", 
#       "codings.rsm", 
       "codings<-", 
       "contour.lm", 
       "cube", 
       "decode.data", 
       "djoin", 
       "dupe", 
       "FO", 
       "foldover", 
       "heli", 
       "image.lm", 
       "is.coded.data", 
       "loftest", 
#       "lsm.basis.rsm", 
       "model.data", 
#       "names<-.coded.data", 
       "PE", 
       "persp.lm", 
       "PQ", 
#       "print.coded.data", 
#       "print.summary.rsm", 
       "recode.data", 
#       "recover.data.rsm", 
       "rsm", 
       "SO", 
       "star", 
       "stdorder", 
       "steepest", 
       "summary.rsm", 
       "truenames", 
#       "truenames.coded.data", 
       "truenames<-", 
#       "truenames<-.coded.data", 
       "TWI", 
       "val2code", 
       "varfcn", 
       "xs"
)
