plotConnectivity: Plot a connectivity matrix

Description Usage Arguments Details Value

View source: R/plotting.R

Description

Plot a connectivity matrix

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
plotConnectivity(
  connObj,
  slctROI = NULL,
  grouping = "type",
  connectionMeasure = "weightRelative",
  xaxis = c("inputs", "outputs"),
  facetInputs = NULL,
  facetOutputs = NULL,
  theme = theme_minimal(),
  cmax = NULL,
  replacementLabels = NULL,
  orderIn = NULL,
  orderOut = NULL,
  legendName = NULL,
  showTable = "inputs",
  switch = NULL,
  flipy = FALSE,
  flipy_facet = FALSE
)

Arguments

connObj

A connectivity object. Either a connectivity table, a matrix with dimnames Inputs and Outputs(as returned by connectivityMatrix) or a connectivityCluster object.

slctROI

For connectivity tables, you can specify a ROI

grouping

Which variable to use. Will be ignored when connObj is a connectivityCluster (the decision has already been made while clustering). Any variable postfixed by "to" or "from" in the table is a valid value, as well as "bodyid" and "neuron"

connectionMeasure

Which variable to use as a plotting value

xaxis

Should inputs or outputs be on the x axis (will match the value to "inputs" or "outputs")

facetInputs

Variable to facet the inputs on (nothing by default)

facetOutputs

Variable to facet the outputs on (nothing by default)

theme

A theme to use

cmax

Maximum fill value for the color scale. By default the maximum value found in the table.

replacementLabels

A column prefix to use as a replacement for the axis labels (useful to replace bodyids with names for example)

orderIn

A vector of input bodyid/types/names in the desired order, or a connectivityCluster object. Optional ordering of the inputs (ignored and replaced by the clustering order if connObj is a connectivityCluster).

orderOut

A vector of output bodyid/types/names in the desired order, or a connectivityCluster object. Optional ordering of the outputs (ignored and replaced by the clustering order if connObj is a connectivityCluster).

legendName

Optional override the default name for the color legend (by default a prettification of connectionMeasure)

showTable

When both inputs and outputs have been used for a clustering (via clusterBag), which connectivity table to show.

switch

To be passed to ggplot2::facet_grid to switch where the facet labels are displayed.

flipy

Option to flip the y axis order

flipy_facets

Option to flip the y axis facets order

Details

orderIn and orderOut are passed as levels to a factor to order the axis.

Value

A ggplot object


jayaraman-lab/neuprintrExtra documentation built on Dec. 20, 2021, 10 p.m.