window_plot: Generate a plot of FAVA in sliding windows.

View source: R/window_fava.R

window_plotR Documentation

Generate a plot of FAVA in sliding windows.

Description

This function generates a plot of normalized or unnormalized, weighted or unweighted FAVA computed in sliding windows across samples for one or many groups of samples.

Usage

window_plot(window_fava, alpha = 0.5)

Arguments

window_fava

The output of window_fava.

alpha

Optional; number between 0 and 1 specifying the opacity of the horizontal lines plotted. Default is alpha = 0.5.

Value

A ggplot2 object.

Examples

A = matrix(c(.3,.7,0,.1,0,.9,.2,.5,.3,.1,.8,.1,.3,.4,.3,.6,.4,0,0,.5,.5),
           ncol = 3, byrow = TRUE)
window_out = window_fava(relab_matrix = A, window_size = 4, normalized = TRUE)
window_out$window_data
window_out$window_plot

FAVA documentation built on April 4, 2025, 4:47 a.m.