plot.multicomp | R Documentation |
Multiple comparisons plot that gives independent user control
over the appearance of the significant and not significant
comparisons.
In R, both plot.multicomp
plot.multicomp.hh
coerce their argument
to an "glht"
object and plots
that with the appropriate plot
method.
In R, plot.multicomp.adjusted
replaces the bounds
calculated by multcomp:::confint.glht
with bounds based on
a common standard error for a set of anova tables that are
partitioned for the simple effects on an analysis conditioned on
the levels of one of the factors.
In S-Plus,
plot.multicomp.hh
augments the standard plot.multicomp
to
give additional user arguments to control the appearance of the plot.
plotMatchMMC
uses the plot.multicomp.hh
code.
plotMatchMMC
must immediately follow a plot of an
mmc.multicomp
object and is applied to either the $mca
or $lmat
component of the mmc.multicomp
object.
plotMatchMMC
is used as a tiebreaker plot for the MMC
plot. plotMatchMMC
matches the horizontal scaling of the
MMC
plot and displays the individual contrasts in the same
order as the MMC
plot. See mmc
for examples.
These functions are no longer recommended. Use mmcplot
instead.
## S3 method for class 'multicomp'
plot(x, ...) ## R only
## S3 method for class 'multicomp.hh'
plot(x, ylabel = x$ylabel, href = 0, uniform = TRUE,
plt.in = c(0.2, 0.9, 0.1, 0.9),
x.label.adj=1,
xrange.include=href,
xlim,
comparisons.per.page=21,
col.signif=1, col.not.signif=1,
lty.signif=4, lty.not.signif=4,
lwd.signif=1, lwd.not.signif=1,
...,
xlabel.print=TRUE, y.axis.side=2, ylabel.inside=FALSE)
plotMatchMMC(x, ...,
xlabel.print=FALSE,
cex.axis=par()$cex.axis,
col.signif='red', main="",
ylabel.inside=FALSE,
y.axis.side=4,
adjusted=FALSE)
x |
A |
ylabel |
Y label on graph. |
y.axis.side |
Y labels are on the left by default when plotting a
|
... |
other arguments to |
ylabel.inside |
Logical value, if |
href |
reference line for the intervals. The default is 0. S-Plus only. |
xrange.include |
|
uniform |
S-Plus only. Logical value, if |
plt.in |
S-Plus only. Value for |
x.label.adj |
S-Plus only. This is the |
xlim |
x-range of the plot. |
comparisons.per.page |
The default S-Plus |
lty.signif , lwd.signif |
Line type, and line width for significant comparisons. S-Plus only. |
col.signif |
Color for significant comparisons. S-Plus only for
|
col.not.signif , lty.not.signif , lwd.not.signif |
Color, line type, and line width for non-significant comparisons. S-Plus only. |
xlabel.print |
logical. When |
cex.axis |
|
main |
Main title for plot. |
adjusted |
Logical. When |
plot.multicomp
plots a "multicomp"
object. In S-Plus, this
masks the standard plot.multicomp
in order to provide additional
arguments for controlling the appearance. It defaults to the standard
appearance. In R, it coerces its argument to a "glht"
object and plots
that with the appropriate plot
method.
The multiple comparisons calculations in R and S-Plus use
completely different packages.
Multiple comparisons in R are based on glht
.
Multiple comparisons in S-Plus are based on multicomp
.
The MMC plot in the HH package is the same in both systems.
The details of getting the plot differ.
Richard M. Heiberger <rmh@temple.edu>
Heiberger, Richard M. and Holland, Burt (2015). Statistical Analysis and Data Display: An Intermediate Course with Examples in R. Second Edition. Springer-Verlag, New York. https://link.springer.com/book/10.1007/978-1-4939-2122-5
Heiberger, R. M. and Holland, B. (2006). "Mean–mean multiple comparison displays for families of linear contrasts." Journal of Computational and Graphical Statistics, 15:937–955.
mmc
in both languages,
glht
.
## data and ANOVA
data(catalystm)
catalystm1.aov <- aov(concent ~ catalyst, data=catalystm)
summary(catalystm1.aov)
catalystm.mca <-
if.R(r=glht(catalystm1.aov, linfct = mcp(catalyst = "Tukey")),
s=multicomp(catalystm1.aov, plot=FALSE))
if.R(s=plot(catalystm.mca),
r=plot(confint(catalystm.mca, calpha=qtukey(.95, 4, 12)/sqrt(2))))
## calpha is strongly recommended in R with a large number of levels
## See ?MMC for details.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.