Learn R Programming

paleofire (version 1.1.8)

plot.pfKruskal: Plot a "pfKruskal" object.

Description

Plot a "pfKruskal" object using boxplots and showing significant differences between the periods using letters.

Usage

"plot"(x, trend = FALSE, outliers = FALSE, xlim = NULL, ylim = NULL, ...)

Arguments

x
An object returned by pfKruskal.
trend
Logical, show trend using linear regression?
outliers
Logical, show outliers?
xlim
Numeric, x axis limits.
ylim
Numeric, y axis limits.
...
...

Value

Return a ggplot2 "gg" object.

Details

If two periods share the same letter their rank (median) is not significantly different at the confidence level specified by alpha. If not, equality could be rejected at the confidence level specified by alpha.

See Also

pfKruskal

Examples

Run this code

## Composite charcoal record for Western Boreal North America:
ID=pfSiteSel(id_region=="WNA0" & l12==1)
plot(ID)
## Transform data
res3=pfTransform(ID,method=c("MinMax","Box-Cox","Z-Score"),BasePeriod=c(200,4000))

## Composite
comp=pfComposite(res3,bins=seq(from=-500,to=12500,by=1000))
plot(comp)

## Kruskal Wallis Anova
comparison=pfKruskal(comp)

plot(comparison)

# p=plot(comparison)
# require(ggplot2)
# p+ggtitle("my title")

Run the code above in your browser using DataLab