Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve recursion efficiency in check1D and check2D #51

Open
mfasiolo opened this issue Dec 4, 2018 · 0 comments
Open

Improve recursion efficiency in check1D and check2D #51

mfasiolo opened this issue Dec 4, 2018 · 0 comments

Comments

@mfasiolo
Copy link
Owner

mfasiolo commented Dec 4, 2018

When check1D is called with a list as argument (e.g. check1D(o, list("x1", "x2", "x3"))) it is then internally called recursively (only one level of recursion) and a plotGam object is returned containing a list 3 ggplots.

However, the residuals are recomputed 3 times (in this case), hence it would be be better to compute them once, and then call the rest of the code. Same for check2D, where this could be particularly important if we are checking all pairs of variables.

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

No branches or pull requests

1 participant