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
use insight::get_variances, add overdispersion() and zerocount() funs #24
Conversation
@DominiqueMakowski What would you say, do functions to test overdispersion and zero-inflation fit into this package? Maybe we should rename |
These functions are great!!! (I was not aware of their existence and purpose, they would definitely benefit from some more visibility) As for the names, I would tend to agree that Maybe we should think of a new "class" of functions, prefixed with Based on recent questions that I had from students, other possible functions (not necesserily implemented in |
yes, the As for |
sjstats' comprehensiveness strikes again! 😅 Let's leave these there PS: I will redirect the students to sjstats then, I think it's a good experience for them to make the tests that they learn in class and see that indeed it fails in most of the cases, to increase awareness that we are doing things with 1) questionable assumptions that 2) we do not respect anyway :) |
I've took initiative to rename:
Also, I would like to rename @param random Should it take the random effects into account? Can be \code{TRUE}, \code{FALSE}
or a formula indicating which group-level parameters to condition on when making predictions.
The data argument may include new levels of the grouping factors that were specified when the
model was estimated, in which case the resulting posterior predictions marginalize over the relevant
variables (see \code{posterior_predict.stanreg}). # Deal with random
if (insight::model_info(model)$is_mixed & random) {
if (!insight::find_random(model, flatten = TRUE) %in% names(data)) {
warning("Could not find random effects in data. Will turn `random` to FALSE.")
random <- FALSE
}
}
if (random == TRUE) {
re.form <- NULL
} else if (random == FALSE) {
re.form <- NA
} This way of handling random works in my narrow experience, but I am not certain it is able to deal with all the edge-cases. Thus, it might be interesting to find a consistent and general way of addressing it. |
No description provided.