Skip to contents

plot_metrics creates plots of all the summary metrics calculated by get_metrics. By making the 'metric_dfs_by_net' argument a list of multiple outputs from get_metrics, you can plot the metrics from multiple networks on the same graphs. The x-axis is based on the network subset sizes.

Usage

plot_metrics(
  metric_dfs_by_net,
  title_text,
  subtitle_text = "",
  perTF,
  sum = TRUE,
  percent = FALSE,
  mean = FALSE,
  median = FALSE,
  annotation_overlap = FALSE,
  size = TRUE
)

Arguments

metric_dfs_by_net

a list of outputs from get_metrics

title_text

text for the title of every plot; generally the names of the networks

subtitle_text

text for the subtitle of every plot

perTF

boolean whether the network subset sizes were specified as average target genes per TF; changes the x-axis label

sum

boolean whether to plot the 'sum' metric, which is the sum of the negative log base 10 of the p-value for the top term of each source node minus the penalty times the total number of source nodes.

percent

boolean whether to plot the 'percent' metric, which is the percent of source nodes with at least one term with a FDR below a threshold

mean

boolean whether to plot the 'mean' metric, which is the mean negative log base 10 of the p-value for the top term of each source node regardless of significance

median

boolean whether to plot the 'median' metric, which is the median negative log base 10 of the p-value for the top term of each source node regardless of significance

annotation_overlap

boolean whether to plot the 'annotation_overlap' metric, which is the percent of source nodes that are annotated to at least one of the 16 GO terms for which their target genes are most enriched

size

boolean whether to plot the 'size' metric, which is the number of source nodes in the network subset that have more than one target gene with annotations

Value

a list of data.frames each containing values of one metric. The column names denote the network and subset. The first row of each data.frame is from the real networks; the rest are from permuted networks.