View source: R/plot_microstates.R
This function returns a list of plots, one for each condition entered in the fitting or segmentation in Cartool.
1 2 3 4 5 6 7 8 | plot_microstates(
path_.seg,
vline_onset = FALSE,
time_ms = "none",
size_hist = 2,
palette = "default",
scale = "automatic"
)
|
path_.seg |
Path to the .seg file from Cartool (e.g. "C:/.../my_microstates.seg) |
vline_onset |
Argument where to specify if the plot should include a vertical line at the onet of the stimulus (where time = 0). Disable this option when working with response aligned data or time in time frames. Default is FALSE. |
time_ms |
An array describing the time in ms. Default is "none" implying that time in time frames will be taken into account.To create an array of time values in ms, here is an example. Imagine epochs of 155 time frames (downsampled by 4), here could be an array : c(seq(-100, 0, by = 4), seq(5,520, by = 4)) |
size_hist |
The microstates maps are represented by segments present at each time frame. However, depending on the width of the desired plot, there might be spaces between segments. This parameter allows the user to change the width of the segment to cover the entire space. To better understand the purpose of this parameter, try setting it to 0.5 and to 4 and see the difference. Defaut value is 2, it is supposed to be a good compromise. |
palette |
A string array containing the color names to include in the plot. Across all plots, maps number will have the same colors. by default the color palette is default, another possibility is to set it on "alternative". This option will use different colors The color can be customized by indicating the path to an Excel file containing new color names. The first column should contain the maps numbers and the second column the color names. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.