useDynLib(L1pack, .registration = TRUE)

## required package
import(fastmatrix)

## base packages
importFrom("grDevices",
           dev.interactive)

importFrom("graphics",
           abline, mtext, par, plot, points, strheight, strwidth, text, title)

importFrom("stats", # some S3 generics for which we define methods
           .checkMFClasses, .getXlevels, coef, delete.response, fitted, integrate, 
           lsfit, model.frame, model.matrix, model.response, na.fail, na.omit, na.pass, 
           pnorm, qnorm, qqnorm, quantile, residuals, runif, simulate, terms, var, vcov)

importFrom("utils", 
           setTxtProgressBar, txtProgressBar)

## Our Exports:
export(dlaplace, dmLaplace, envelope.Laplace, l1ccc, l1fit, lad, lad.fit, lad.fit.BR, 
       lad.fit.EM, LaplaceFit, plaplace, qlaplace, rlaplace, rmLaplace, spatial.median, 
       WH.Laplace)

## Exported S3 methods
export(simulate.lad)

## register S3 methods
S3method(confint, lad)
S3method(deviance, lad)
S3method(fitted, lad)
S3method(logLik, lad)
S3method(plot, lad)
S3method(predict, lad)
S3method(print, lad)
S3method(print, LaplaceFit)
S3method(print, L1ccc)
S3method(print, spatial.median)
S3method(print, summary.lad)
S3method(residuals, lad)
S3method(simulate, lad)
S3method(summary, lad)
S3method(vcov, lad)
