Learn R Programming

gmwm (version 2.0.0)

plot.wvar.imu: Wrapper Function to Plot the Wavelet Variances of IMU Object

Description

Creates a graph of the wavelet variance for imu object.

Usage

"plot"(x, split = TRUE, CI = TRUE, background = "white", transparence = 0.1, line.color = NULL, line.type = NULL, point.size = NULL, point.shape = NULL, CI.color = NULL, title = "Haar Wavelet Variance Representation", title.size = 15, axis.label.size = 13, axis.tick.size = 11, axis.x.label = expression(paste("Scale ", tau)), axis.y.label = expression(paste("Wavelet Variance ", nu)), facet.label.size = 13, facet.label.background = "#003C7D33", legend.title = "Axis", legend.key.size = 1.3, legend.title.size = 13, legend.text.size = 13, scales = "free_y", ...)

Arguments

x
A wvar.imu object.
split
A boolean that indicates whether the graphs should be separate (TRUE) or graphed ontop of each other (FALSE).
CI
A boolean that indicates whether the confidence interval should be plotted.
background
A string that determines the graph background. It can be 'grey' or 'white'.
transparence
A double that ranges from 0 to 1 that controls the transparency of the confidence interval.
line.color
A vector of string that indicates the color of the line drawn (e.g. black, blue, red, etc.)
line.type
A vector of string that indicates the type of line (e.g. solid, dotted, etc.)
point.size
A vector of integer that indicates the size of points on lines.
point.shape
A vector of integer that indicates the shape of points on lines.
CI.color
A string that indicates the color of the confidence interval (e.g. black, red, #003C7D, etc.)
title
A string that indicates the title of the graph.
title.size
An integer that indicates the size of title.
axis.label.size
An integer that indicates the size of label.
axis.tick.size
An integer that indicates the size of tick mark.
axis.x.label
A string that indicates the label on x axis.
axis.y.label
A string that indicates the label on y axis.
facet.label.size
An integer that indicates the size of facet label.
facet.label.background
A string that indicates the background color of the facet label.
legend.title
A string that indicates the title of legend. It is onlly used when split = FALSE.
legend.key.size
A double that indicates the size of key (in centermeters) on legend. It is onlly used when split = FALSE.
legend.title.size
An integer that indicates the size of title on legend. It is onlly used when split = FALSE.
legend.text.size
An integer that indicates the size of key label on legend. It is onlly used when split = FALSE.
scales
Same as scales in facet_grid() in ggplot2 package: should scales be fixed ("fixed"), free ("free"), or free in one dimension ("free_x", "free_y"). The default is "free_y" in this function.
...
Additional options.

Value

A panel containing the graph of an IMU sensor.

Examples

Run this code
## Not run: 
# if(!require("imudata")){
#    install_imudata()
#    library("imudata")
# }
# 
# data(imu6)
# test = imu(imu6, gyros = 1:3, accels = 4:6, freq = 100)
# df = wvar.imu(test)
# 
# ## Plot in split way
# plot(df, split = T)
# plot(df, split = T, CI = F)
# plot(df, split = T, CI = T, line.color = c('black', 'black'), title.size = 18)
# 
# ## Plot in combined way
# plot(df, split = F)
# plot(df, split = F, line.color = c('black', 'green', 'red'), CI.color = c('black', 'green', 'red'))
# ## End(Not run)

Run the code above in your browser using DataLab