View source: R/mixture-regression-predict.R
| plot.latents_mixture_regression | R Documentation |
A fit that classifies persons (id with class_level = "group") is a
trajectory model, and draws the trajectory views of
plot.latents_growth_mixture() (ggplot2): "trajectories" (the
default), "individuals", "coefficients" and "classification". Any
other fit draws base-graphics views: "fitted" (the default),
"coefficients" and "posteriors".
## S3 method for class 'latents_mixture_regression'
plot(
x,
what = NULL,
predictor = NULL,
level = 0.95,
main = NULL,
subtitle = NULL,
time = NULL,
facet = FALSE,
persons = 12L,
max_persons = 120L,
...
)
x |
A fit from |
what |
For a trajectory model: |
predictor |
For |
level |
Confidence level of intervals and bands. |
main |
Plot title; |
subtitle |
For a trajectory model, the subtitle; |
time, facet, persons, max_persons |
For a trajectory model, as in
|
... |
Unused. |
For a trajectory model, a ggplot object (raises
latents_missing_package without ggplot2); otherwise x, invisibly,
called for its plot.
fit <- mixture_regression(score ~ hours, data = study_hours, n_classes = 2,
n_starts = 3, seed = 1)
plot(fit)
plot(fit, what = "coefficients")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.