boost-R / gamboostLSS

Boosting models for fitting generalized additive models for location, shape and scale (GAMLSS) to potentially high dimensional data. The current relase version can be found on CRAN (https://cran.r-project.org/package=gamboostLSS).
26 stars 11 forks source link

adapt mboostLSS_fit() such that it works with FDboost to get FDboostLSS #38

Closed sbrockhaus closed 7 years ago

sbrockhaus commented 7 years ago

Pull request to see the necessary changes to gamboostLSS to use mboostLSS_fit() in FDboostLSS(). @hofnerb @mayrandy @ja-thomas

The according FDboostLSS() in FDboost would then be very easy, as

## function that calls FDboost for each distribution parameter
FDboostLSS <- function(formula, timeformula, data = list(), families = GaussianLSS(),
                       control = boost_control(), weights = NULL, 
                       method = c("cyclic", "noncyclic"), ...){

  cl <- match.call()
  if(is.null(cl$families)) cl$families <- families

  ## warnings for functional response are irrelevant for scalar response  
  if( !is.null(timeformula) && timeformula != ~bols(1) ){
    message("No smooth offsets over time are used, just global scalar offsets.")
    message("No integration weights are used to compute the loss for the functional response.")
  }
  method <- match.arg(method)

  fit <- mboostLSS_fit(formula = formula, timeformula = timeformula, 
                       data = data, families = families,
                       control = control, weights = weights, ...,
                       fun = FDboost, funchar = "FDboost", call = cl, 
                       method = method)

  return(fit)
}
hofnerb commented 7 years ago

@sbrockhaus, can you provide general changes such as the good changes to the manual directly in the master branch? As we are planning to release a new version soon, this would be very helpful.

sbrockhaus commented 7 years ago

Yes sure, I commited the changes in the manual directly to the master branch, see https://github.com/boost-R/gamboostLSS/commit/9c8cc8a17b703c0c286b910fcc6fc2a8825943de

@ja-thomas / @mayrandy could you please check my changes in the manual of mbostLSS? In particular those concerning non-cyclic fitting.

sbrockhaus commented 7 years ago

Thank you very much for your comments! I am working on it and I think I will have a new version by Tuesday.

hofnerb commented 7 years ago

@sbrockhaus The manual looks very good! Thank you very much!!! (I am looking forward to your further input which is always fantastic and of great help)

sbrockhaus commented 7 years ago

Worked through (and solved?) all comments, except for the problem with fitted() / fitted.mboost(). I will think about it...

coveralls commented 7 years ago

Coverage Status

Changes Unknown when pulling 95c79f2d97ec02ed8c88adfadabcf37b56f525ea on sbrockhaus:master into on boost-R:master.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-1.08%) to 84.243% when pulling 833359289f9b9946353caf3b3f06faa08ba43582 on sbrockhaus:master into 2599aed3de6884b9fc2cca45879477ebf5b5ca1f on boost-R:master.