pyGAM icon indicating copy to clipboard operation
pyGAM copied to clipboard

model reuse

Open yuzhou93 opened this issue 2 years ago • 1 comments

@dswah Thanks for creating this great package. I've been learning GAM and this package for the last few weeks, and I am at a stage pretty comfortable on the math/implementation behind it. One question I have is how do I save the model and reuse it for prediction? And as I am working in finance industry, most of the people are using excel. Is there away I can call the model from my excel, within the excel I would have a bunch of X that needs to get the prediction from the model?

Thanks in advance for the help.

yuzhou93 avatar Dec 12 '21 21:12 yuzhou93

@dswah Many thanks for this great work! I am quite interested in the same possibility: I need to re-use a trained model (classification problem) in a different environment (JavaScript); How can I use the coefficients of trained smoothing functions for making the predictions? I see that predict function outputs the _linear_predictor result which returns modelmat.dot(b), where can I get modelmat and b?

defelix avatar Feb 26 '22 14:02 defelix