Skip to content

Clarification on the use of include or terms in fitted_samples() #340

Closed Answered by gavinsimpson
Pembs asked this question in Q&A
Discussion options

You must be logged in to vote

I don't know why you think include is a valid argument to predict.gam(), because it isn't. There are two arguments that control which arguments are included in the predictions:

  1. terms, and
  2. exclude

which is why "there isn't explicit documentation as to what include does in the arguments of fitted_samples", although ?fitted_samples does direct you to ?predict.gam (for the ... argument), which would have alerted you to the fact that you had made a mistake.

terms is how you select which terms need to be included in the predictions, while exclude is the complement of terms and indicates which model terms should not be included in the predictions.

If all you want is posterior draws from a spec…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Pembs
Comment options

Answer selected by gavinsimpson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants