plot_model_parameters | R Documentation |
Function to plot the best-fitting parameters of either the 2-component or 3-component model. .
plot_model_parameters(
model_fit,
model,
id_var = "id",
set_size_var = NULL,
condition_var = NULL,
n_col = 2,
return_data = FALSE,
palette = "Dark2"
)
model_fit |
The model fit object containing the parameters to be plotted. |
model |
A string indicating the model that was fit to the data. Currently the options are "2_component", "3_component", "slots", and "slots_averaging". |
id_var |
The column name coding for participant id. |
set_size_var |
The column name (if applicable) coding for the set size of each response. |
condition_var |
The column name (if applicable) coding for the condition of each response. |
n_col |
An integer controlling the number of columns in the resulting plot. |
return_data |
A boolean (TRUE or FALSE) indicating whether the data for the plot should be returned. |
palette |
A character stating the preferred colour palette to use. To see all available palettes, type?scale_colour_brewer into the console. |
If return_data
is set to FALSE
(which it is by
default),the function returns a ggplot2 object visualising the mean model
parameters across participants (if applicable) per set-size (if applicable)
and condition (if applicable).
If return_data
is set to TRUE
, the function returns a
list with two components:
plot:
The ggplot2 object.
data:
A data frame with the data used to generate the plot.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.