R/regression.R

Defines functions regression

Documented in regression

#'regression
#'
#'Performs a Minimum Absolute Residual (L1) Regression
#'
#'@param data dataframe. If \code{NULL} (the default) selects murders dataset.
#'
#'@return a list defining the regression
#'
#'@examples
#'regression()
#'@export
#'



regression <- function(data=NULL){
  if(is.null(data))
    data <-get_data()
  L1pack::l1fit(data$total, data$population, intercept = TRUE, tolerance = 1e-07, print.it = TRUE)
}
unimi-dse/fe8cd6bc documentation built on Feb. 18, 2020, 2:41 a.m.