Package: insight 1.0.0
insight: Easy Access to Model Information for Various Model Objects
A tool to provide an easy, intuitive and consistent access to information contained in various R models, like model formulas, model terms, information about random effects, data that was used to fit the model or data from response variables. 'insight' mainly revolves around two types of functions: Functions that find (the names of) information, starting with 'find_', and functions that get the underlying data, starting with 'get_'. The package has a consistent syntax and works with many different model objects, where otherwise functions to access these information are missing.
Authors:
insight_1.0.0.tar.gz
insight_1.0.0.tar.gz(r-4.5-noble)insight_1.0.0.tar.gz(r-4.4-noble)
insight_1.0.0.tgz(r-4.4-emscripten)insight_1.0.0.tgz(r-4.3-emscripten)
insight.pdf |insight.html✨
insight/json (API)
NEWS
# Install 'insight' in R: |
install.packages('insight', repos = c('https://cran.r-universe.dev', 'https://cloud.r-project.org')) |
Bug tracker:https://github.com/easystats/insight/issues
- fish - Sample data set
Last updated 3 hours agofrom:4c8b81978f. Checks:OK: 2. Indexed: no.
Target | Result | Date |
---|---|---|
Doc / Vignettes | OK | Nov 26 2024 |
R-4.5-linux | OK | Nov 26 2024 |
Exports:all_models_equalall_models_same_classapply_table_themecheck_if_installedclean_namesclean_parameterscolor_ifcolor_textcolor_themecolour_ifcolour_textcompact_charactercompact_listdisplaydownload_modelellipsis_infoexport_tablefind_algorithmfind_formulafind_interactionsfind_offsetfind_parametersfind_predictorsfind_randomfind_random_slopesfind_responsefind_smoothfind_statisticfind_termsfind_transformationfind_variablesfind_weightsformat_alertformat_bfformat_capitalizeformat_ciformat_errorformat_messageformat_numberformat_pformat_pdformat_percentformat_ropeformat_stringformat_tableformat_valueformat_warningformula_okget_auxiliaryget_callget_correlation_slope_interceptget_correlation_slopesget_dataget_datagridget_devianceget_dfget_dispersionget_familyget_interceptget_loglikelihoodget_loglikelihood_adjustmentget_modelmatrixget_parametersget_predictedget_predicted_ciget_predictorsget_priorsget_randomget_residualsget_responseget_sigmaget_statisticget_transformationget_varcovget_varianceget_variance_dispersionget_variance_distributionget_variance_fixedget_variance_interceptget_variance_randomget_variance_residualget_variance_slopeget_weightshas_intercepthas_single_valueis_convergedis_empty_objectis_gam_modelis_mixed_modelis_modelis_model_supportedis_multivariateis_nested_modelsis_nullmodelis_regression_modellink_functionlink_inverseloglikelihoodmodel_infomodel_namen_grouplevelsn_obsn_parametersn_uniquenull_modelobject_has_namesobject_has_rownamesprint_colorprint_colourprint_htmlprint_mdprint_parameterssafe_deparsesafe_deparse_symbolstandardize_column_orderstandardize_namessupported_modelstext_remove_backtickstrim_wsvalidate_argument
Dependencies:
Exporting tables with captions and footers
Rendered fromexport.Rmd
usingknitr::rmarkdown
on Nov 26 2024.Last update: 2024-11-26
Started: 2022-01-07
Formatting, printing and exporting tables
Rendered fromdisplay.Rmd
usingknitr::rmarkdown
on Nov 26 2024.Last update: 2023-10-12
Started: 2021-02-15
Getting Started with Accessing Model Information
Rendered frominsight.Rmd
usingknitr::rmarkdown
on Nov 26 2024.Last update: 2024-06-05
Started: 2019-07-01
Readme and manuals
Help Manual
Help page | Topics |
---|---|
Checks if all objects are models of same class | all_models_equal all_models_same_class |
Data frame and Tables Pretty Formatting | apply_table_theme export_table |
Checking if needed package is installed | check_if_installed |
Get clean names of model terms | clean_names clean_names.character |
Get clean names of model parameters | clean_parameters |
Color-formatting for data columns based on condition | color_if colour_if |
Remove empty strings from character | compact_character |
Remove empty elements from lists | compact_list |
Generic export of data frames into formatted tables | display display.data.frame print_html print_html.data.frame print_md print_md.data.frame |
Download circus models | download_model |
Gather information about objects in ellipsis (dot dot dot) | ellipsis_info ellipsis_info.default |
Find sampling algorithm and optimizers | find_algorithm |
Find model formula | find_formula find_formula.default find_formula.nestedLogit formula_ok |
Find interaction terms from models | find_interactions |
Find possible offset terms in a model | find_offset |
Find names of model parameters | find_parameters find_parameters.default |
Find model parameters from models with special components | find_parameters.averaging |
Find names of model parameters from marginal effects models | find_parameters.betamfx |
Find names of model parameters from Bayesian models | find_parameters.BGGM find_parameters.brmsfit |
Find model parameters from estimated marginal means objects | find_parameters.emmGrid |
Find names of model parameters from generalized additive models | find_parameters.gam find_parameters.gamlss |
Find names of model parameters from mixed models | find_parameters.glmmTMB |
Find names of model parameters from zero-inflated models | find_parameters.zeroinfl |
Find names of model predictors | find_predictors find_predictors.default |
Find names of random effects | find_random |
Find names of random slopes | find_random_slopes |
Find name of the response variable | find_response find_response.joint find_response.mjoint |
Find smooth terms from a model object | find_smooth |
Find statistic for model | find_statistic |
Find all model terms | find_terms find_terms.default |
Find possible transformation of model variables | find_transformation find_transformation.default |
Find names of all variables | find_variables |
Find names of model weights | find_weights |
Sample data set | fish |
Bayes Factor formatting | format_bf |
Capitalizes the first letter in a string | format_capitalize |
Confidence/Credible Interval (CI) Formatting | format_ci format_ci.numeric |
Format messages and warnings | format_alert format_error format_message format_warning |
Convert number to words | format_number |
p-values formatting | format_p |
Probability of direction (pd) formatting | format_pd |
Percentage in ROPE formatting | format_rope |
String Values Formatting | format_string format_string.character |
Parameter table formatting | format_table |
Numeric Values Formatting | format_percent format_value format_value.data.frame format_value.numeric |
Get auxiliary parameters from models | get_auxiliary get_dispersion get_dispersion.default |
Get the model's function call | get_call |
Get the data that was used to fit the model | get_data get_data.afex_aov get_data.default get_data.glmmTMB get_data.rma |
Create a reference grid | get_datagrid get_datagrid.data.frame get_datagrid.default get_datagrid.emmGrid get_datagrid.factor get_datagrid.numeric get_datagrid.slopes |
Model Deviance | get_deviance get_deviance.default |
Extract degrees of freedom | get_df get_df.default |
A robust alternative to stats::family | get_family |
Get the value at the intercept | get_intercept |
Log-Likelihood and Log-Likelihood correction | get_loglikelihood get_loglikelihood.lm get_loglikelihood_adjustment loglikelihood |
Model Matrix | get_modelmatrix |
Get model parameters | get_parameters get_parameters.default |
Get model parameters from marginal effects models | get_parameters.betamfx |
Get model parameters from models with special components | get_parameters.betareg |
Get model parameters from Bayesian models | get_parameters.BFBayesFactor get_parameters.BGGM get_parameters.brmsfit |
Get model parameters from estimated marginal means objects | get_parameters.emmGrid |
Get model parameters from generalized additive models | get_parameters.gamm |
Get model parameters from mixed models | get_parameters.glmmTMB |
Get model parameters from htest-objects | get_parameters.htest |
Get model parameters from zero-inflated and hurdle models | get_parameters.zeroinfl |
Model predictions (robust) and their confidence intervals | get_predicted get_predicted.default get_predicted.gam get_predicted.lm get_predicted.lmerMod get_predicted.principal get_predicted.stanreg |
Confidence intervals around predicted values | get_predicted_ci get_predicted_ci.default |
Get the data from model predictors | get_predictors |
Get summary of priors used for a model | get_priors get_priors.brmsfit |
Get the data from random effects | get_random |
Extract model residuals | get_residuals get_residuals.default |
Get the values from the response variable | get_response get_response.default get_response.nestedLogit |
Get residual standard deviation from models | get_sigma |
Get statistic associated with estimates | get_statistic get_statistic.default get_statistic.emmGrid get_statistic.gee get_statistic.glmmTMB |
Return function of transformed response variables | get_transformation |
Get variance-covariance matrix from models | get_varcov get_varcov.aov get_varcov.betamfx get_varcov.betareg get_varcov.brmsfit get_varcov.clm2 get_varcov.default get_varcov.glmgee get_varcov.glmmTMB get_varcov.hurdle get_varcov.MixMod get_varcov.mixor get_varcov.nestedLogit get_varcov.truncreg |
Get variance components from random effects models | get_correlation_slopes get_correlation_slope_intercept get_variance get_variance.glmmTMB get_variance.merMod get_variance_dispersion get_variance_distribution get_variance_fixed get_variance_intercept get_variance_random get_variance_residual get_variance_slope |
Get the values from model weights | get_weights get_weights.default |
Checks if model has an intercept | has_intercept |
Convergence test for mixed effects models | is_converged |
Check if object is empty | is_empty_object |
Checks if a model is a generalized additive model | is_gam_model |
Checks if a model is a mixed effects model | is_mixed_model |
Checks if an object is a regression model or statistical test object | is_model is_regression_model |
Checks if a regression model object is supported by the insight package | is_model_supported supported_models |
Checks if an object stems from a multivariate response model | is_multivariate |
Checks whether a list of models are nested models | is_nested_models |
Checks if model is a null-model (intercept-only) | is_nullmodel |
Get link-function from model object | link_function link_function.betamfx link_function.betareg link_function.DirichletRegModel link_function.gamlss |
Get link-inverse function from model object | link_inverse link_inverse.betamfx link_inverse.betareg link_inverse.DirichletRegModel link_inverse.gamlss |
Access information from model objects | model_info model_info.default |
Name the model | model_name model_name.default |
Count number of random effect levels in a mixed model | n_grouplevels |
Get number of observations from a model | n_obs n_obs.afex_aov n_obs.glm n_obs.stanmvreg n_obs.svyolr |
Count number of parameters in a model | n_parameters n_parameters.brmsfit n_parameters.default n_parameters.gam n_parameters.glmmTMB n_parameters.merMod n_parameters.zeroinfl |
Compute intercept-only model for regression models | null_model |
Check names and rownames | object_has_names object_has_rownames |
Coloured console output | color_text color_theme colour_text print_color print_colour |
Prepare summary statistics of model parameters for printing | print_parameters |
Standardize column order | standardize_column_order standardize_column_order.parameters_model |
Standardize column names | standardize_names standardize_names.parameters_model |
Remove backticks from a string | text_remove_backticks text_remove_backticks.data.frame |
Small helper functions | has_single_value n_unique n_unique.default safe_deparse safe_deparse_symbol trim_ws trim_ws.data.frame |
Validate arguments against a given set of options | validate_argument |