| plotFANOVA {fdANOVA} | R Documentation | 
Plot Univariate Functional Data
Description
Univariate functional observations with or without indication of groups as well as mean functions of samples are plotted. We assume that n univariate functional observations are observed on a common grid of \mathcal{T} design time points equally spaced in I=[a,b] (see Section 3.1 of the vignette file, vignette("fdANOVA", package = "fdANOVA")).
Usage
plotFANOVA(x, group.label = NULL, int = NULL, separately = FALSE,
           means = FALSE, smooth = FALSE, ...)
Arguments
| x | a  | 
| group.label | a character vector containing group labels. Its default value means that all functional observations are drawn without division into groups. | 
| int | a vector of two elements representing the interval  | 
| separately | a logical indicating how groups are drawn. If  | 
| means | a logical indicating whether to plot only group mean functions. | 
| smooth | a logical indicating whether to plot reconstructed data via smoothing splines instead of raw data. | 
| ... | additional arguments not used. | 
Author(s)
Tomasz Gorecki, Lukasz Smaga
See Also
fanova.tests, fmanova.ptbfr, fmanova.trp
Examples
# Some of the examples may run some time.
# gait data (both features)
library(fda)
gait.data.frame <- as.data.frame(gait)
x.gait <- vector("list", 2)
x.gait[[1]] <- as.matrix(gait.data.frame[, 1:39])
x.gait[[2]] <- as.matrix(gait.data.frame[, 40:78])
# vector of group labels
group.label.gait <- rep(1:3, each = 13)
plotFANOVA(x = x.gait[[1]], int = c(0.025, 0.975))
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975))
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), separately = TRUE)
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), means = TRUE)
plotFANOVA(x = x.gait[[1]], int = c(0.025, 0.975), smooth = TRUE)
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), smooth = TRUE)
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), separately = TRUE, smooth = TRUE)
plotFANOVA(x = x.gait[[1]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), means = TRUE, smooth = TRUE)
plotFANOVA(x = x.gait[[2]], int = c(0.025, 0.975))
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975))
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), separately = TRUE)
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), means = TRUE)
plotFANOVA(x = x.gait[[2]], int = c(0.025, 0.975), smooth = TRUE)
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), smooth = TRUE)
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), separately = TRUE, smooth = TRUE)
plotFANOVA(x = x.gait[[2]], group.label = as.character(group.label.gait),
           int = c(0.025, 0.975), means = TRUE, smooth = TRUE)
# Canadian Weather data (both features)
library(fda)
x.CW <- vector("list", 2)
x.CW[[1]] <- CanadianWeather$dailyAv[,,1]
x.CW[[2]] <- CanadianWeather$dailyAv[,,2]
# vector of group labels
group.label.CW <- rep(c("Eastern", "Western", "Northern"), c(15, 15, 5))
plotFANOVA(x = x.CW[[1]])
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW))
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW),
           separately = TRUE)
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW),
           means = TRUE)
plotFANOVA(x = x.CW[[1]], smooth = TRUE)
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW),
           smooth = TRUE)
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW),
           separately = TRUE, smooth = TRUE)
plotFANOVA(x = x.CW[[1]], group.label = as.character(group.label.CW),
           means = TRUE, smooth = TRUE)
plotFANOVA(x = x.CW[[2]])
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW))
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW),
           separately = TRUE)
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW),
           means = TRUE)
plotFANOVA(x = x.CW[[2]], smooth = TRUE)
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW),
           smooth = TRUE)
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW),
           separately = TRUE, smooth = TRUE)
plotFANOVA(x = x.CW[[2]], group.label = as.character(group.label.CW),
           means = TRUE, smooth = TRUE)