Description Usage Arguments Details See Also
View source: R/plot_continuous_var.R
plot_continuous_var
creates a plot of how the mixture proportions
change according to a continuous covariate, as well as plots of the mixture
proportions for the individuals with minimum, median, and maximum covariate
values. Called by output_JAGS
if any continuous effects are in
the model.
1 2 3 4 5 6 7 8 | plot_continuous_var(
jags.1,
mix,
source,
output_options,
alphaCI = 0.05,
exclude_sources_below = 0.1
)
|
jags.1 |
output from |
mix |
output from |
source |
output from |
output_options |
list containing options for plots and saving, passed from |
alphaCI |
alpha level for credible intervals (default = 0.05, 95% CI) |
exclude_sources_below |
don't plot sources with median proportion below this level for entire range of continuous effect variable (default = 0.1) |
MixSIAR fits a continuous covariate as a linear regression in ILR/transform-space. Two terms are fit for the proportion of each source: an intercept and a slope. The plotted line uses the posterior median estimates of the intercept and slope, and the lines are curved because of the ILR-transform back into proportion-space. The 95% credible intervals are shaded.
If the model contains both a continuous AND a categorical (factor) covariate, MixSIAR fits a different intercept term for each factor level and all levels share the same slope term.
Francis et al. 2011
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.