View source: R/plotting-fxns.R
pic_stat_svar_plot | R Documentation |
Plot the contrasts derived from a rescaled 'unit.tree' against their expected variances.
pic_stat_svar_plot( x, xlab = "Variance", ylab = "Contrast", las = 1, col = NA, pch = 19, cex = 1, lwd = 2, ... )
x |
a |
xlab |
x-axis label. Defaults to "Variance". |
ylab |
y-axis label. Defaults to "Contrast". |
las |
plot parameter (see |
col |
plot colours. The first colour is the colour of the points, the second, the colour of the regression line. If no argument, uses default colours. |
pch |
plot parameter (see |
cex |
plot parameter (see |
lwd |
plot parameter (see |
... |
additional arguments to be passed to |
This function generates a plot of the observed contrasts versus their
expected variances (see pic
).
The slope of this plot is equal to
the test statistic pic_stat_svar
and is used as a default test statistic in
calculate_pic_stat
.
If the model is a good fit to the data (i.e. an adequate model), the slope ~ 0. The purpose of the plot is to get a quick visual glance at the data and to assess whether or not the model inadequacy may be driven by outliers.
The function can currently only take a single unit.tree (does not integrate across multiple trees).
make_unit_tree
, calculate_pic_stat
,
pic_stat_svar
## finch data data(finch) phy <- finch$phy data <- finch$data[,"wingL"] u <- make_unit_tree(phy, data=data) pic_stat_svar_plot(u)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.