Skip to content

Instantly share code, notes, and snippets.

@josef-pkt
Created January 30, 2019 00:50
Show Gist options
  • Save josef-pkt/29ad2116e9af0864e5100ded89efe1f5 to your computer and use it in GitHub Desktop.
Save josef-pkt/29ad2116e9af0864e5100ded89efe1f5 to your computer and use it in GitHub Desktop.
Basic GAM example with formula after merge
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@josef-pkt
Copy link
Author

The docstring says list of dict, because splines could have several variables and we need several splines. Try brackets [ ] around the dict.

You can inspect the bsplines instance to see how the knots where set.
Note: in Bsplines everything is in list of splines, e.g. from above bs = BSplines(x_spline, df=[12, 10], degree=[3, 3])

AFAICS, [s.knots for s in bs.smoothers] should show the knots for each univariate bspline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment