business-science / gammodels

The parsnip backend for GAM Models.
https://business-science.github.io/gammodels/
Other
7 stars 3 forks source link

First Version Classif Mode And Tuning Params #10

Closed AlbertoAlmuinha closed 3 years ago

AlbertoAlmuinha commented 3 years ago

Hi @mdancho84

I closed the previous PR in order to send you this one with the updates of the parameters mentioned by Max added to the previous one. I copy what I had written:

" Hi @mdancho84 ,

I have created the first version of the binary classification and have been testing to extend it to more categories from the multinom() family but have not been able to. I think we should open an issue in parsnip to see how we can make that kind of structures pass through parsnip::fit().

Example:

mpg <- ggplot2::mpg
mpg$cyl <- as.numeric(as.factor(mpg$cyl))-1

mgcv::gam(list(cyl ~ s(cty), ~ s(cty), ~s(cty)), 
          family = multinom(K=3), 
          data = mpg)

I have also put some tests for both regression and classification and I have added in the description in suggestions the stats package, as it is the one that contains many of the families that will be used for modeling. "

AlbertoAlmuinha commented 3 years ago

Hi @mdancho84 , Do you think I should open a issue in parsnip to ask how we could pass a formula like the one I copied in the example above? I need that to work to finalize multinom classification.

mdancho84 commented 3 years ago

At the moment I need to understand this further.

AlbertoAlmuinha commented 3 years ago

Perfect Matt!