View source: R/plot_syn_trials.R
plot_syn_trials | R Documentation |
Plot muscle synergies (individual trials)
plot_syn_trials( x, max_syns, trial, dark_mode = FALSE, line_size = 0.6, line_col = "black", sd_col = "grey80", show_plot = TRUE )
x |
Object of class |
max_syns |
Number of synergies to be plotted or how many rows should the final panel be divided into |
trial |
Character: the name of the considered trial, for archiving purposes |
dark_mode |
To enable dark mode |
line_size |
Line thickness |
line_col |
Line colour |
sd_col |
Standard deviation ribbon colour |
show_plot |
Logical, to decide whether plots should be plotted in the active graphic device |
If show_plot
is TRUE (default) plots are also shown in the active graphic device.
Plots can then be saved with the preferred export method, such as ggplot2::ggsave
.
Plots of the unclassified synergies, trial by trial.
# Load some data data(SYNS) # Find maximum number of synergies max_syns <- max(unlist(lapply(SYNS, function(x) x$syns))) # Save a plot with the first (and only, in this case) trial in the list pp <- plot_syn_trials(SYNS[[1]], max_syns = max_syns, trial = names(SYNS)[1], dark_mode = TRUE, line_size = 0.8, line_col = "tomato1", sd_col = "tomato4", show_plot = FALSE )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.