Skip to contents

Plot the networks stored in an experiment object

Usage

plot_networks(
  e,
  network_name = "AD",
  title = NULL,
  channels = c("cfos", "eyfp", "colabel"),
  edge_color = "firebrick",
  height = 15,
  width = 15,
  edge_type = "arc",
  region_legend = TRUE,
  degree_scale_limit = c(1, 10),
  correlation_edge_width_limit = c(0.8, 1),
  image_ext = ".png",
  network_radius = 300,
  print_plot = TRUE,
  graph_theme = NULL,
  label_size = 5,
  label_offset = 0.15,
  save_plot = TRUE
)

Arguments

e

experiment object

network_name

(str, default = "AD")

title

(str, default = NULL) Title of network plot

channels

(str, default = c("cfos", "eyfp", "colabel"))

edge_color

(str, default = "firebrick") Color of the network edges.

height

Height of the plot in inches.

width

width of the plot in inches.

edge_type

(default = "arc") "arc" or "diagonal". Can also be a hexadecimal color code written as a string.

region_legend

(default = TRUE) Boolean determining whether or not to show the region legend categorizing subregions into their largest parent region. Only works well if the Allen ontology is used for the dataset.

degree_scale_limit

(vec, default = c(1,10)) Scale limit for degree size

image_ext

(default = ".png") image extension to the plot as.

print_plot

(bool, default = TRUE) Whether to print the plot as an output. the experiment object output folder.

graph_theme

(default = NULL) Add a ggraph::theme() to the network graph. If NULL, the default is taken.

label_size

(default = 5) Default font size for network region labels.

label_offset

(default = 0.15) Distance of label from nodes.

save_plot

(bool, default = TRUE) Save into the figures subdirectory of the the experiment object output folder.

Value

p_list A list the same length as the number of channels, with each element containing a plot handle for that channel.