plot_CoGAPS_pattern_cor_heatmap: Plot CoGAPS pattern correlation heatmap

Description Usage Arguments Value Examples

View source: R/plot_CoGAPS_pattern_cor_heatmap.R

Description

plot_CoGAPS_pattern_cor_heatmap() plots a heatmap showing the correlation of a CoGAPS pattern set with a grouping variable

Usage

1
2
3
4
5
6
7
8
9
plot_CoGAPS_pattern_cor_heatmap(CoGAPS_res_set = NULL, Pattern_set,
  pattern_subset = NULL, annotation, group_column = NULL, group_vector,
  cluster_groups = F, order_subgroups = F,
  cluster_groups_distance = "correlation",
  cluster_groups_method = "complete", cluster_patterns = F,
  cluster_patterns_vector = NULL,
  cluster_patterns_distance = "correlation",
  cluster_patterns_method = "complete", limits = NULL,
  square_tiles = T)

Arguments

CoGAPS_res_set

a CoGAPS result set. If set to NULL, a Pmeans matrix may be supplied directly as input for the Pattern_set parameter.

Pattern_set

a string specifying the name of a pattern set (e.g. "nP20") in a CoGAPS_res_set. Alternatively, if CoGAPS_res_set is set to NULL, a Pmeans matrix may be supplied directly.

pattern_subset

a vector specifying a subset of the pattern set to be plotted. Defaults to NULL.

annotation

an annotation dataframe. If group_column is set to NULL, must contain logical columns with column names corresponding to values in group_vector. Each logical column (1 or 0) should indicate whether an annotation row is of the value (column name).

group_column

column name of column in annotation object with values corresponding to those in group_vector to use for computing logical columns. Defaults to NULL

group_vector

a vector of with pre-specified values corresponding to those in group_column in the annotation object.

cluster_groups

logical; if groups should be clustered.

order_subgroups

logical; if subgroups should be ordered according to clustering of first subgroup. Subgroups can be specified in a string with separation by " - ".

cluster_groups_distance

distance measure used in clustering groups. Possible values are "correlation", "euclidean", "maximum", "manhattan", "canberra", "binary", or "minkowski" (defined in dist() function.)

cluster_groups_method

clustering method used for groups. Accepts the same values as hclust: "ward.D", "ward.D2", "single", "complete", "average" (=UPGMA), "mcquitty" (=WPGMA), "median" (=WPGMC) or "centroid" (=UPGMC).

cluster_patterns

logical; if patterns should be clustered.

cluster_patterns_vector

a vector specifying the order of patterns. If NULL, patterns will be clustered according to distance and method specified below.

cluster_patterns_distance

distance measure used in clustering patterns. Possible values are the same as cluster_groups_distance().

cluster_patterns_method

clustering method used for patterns. Possible values are the same as cluster_groups_method().

limits

limits of the color scale for the heatmap.

square_tiles

logical; if tiles should be made square

Value

a ggplot object

Examples

1
2
3
4
plot_CoGAPS_pattern_cor_heatmap(CoGAPS_res_set = my_CoGAPS_res, Pattern_set = "nP30",annotation=pData(cds), 
group_column=NULL, group_vector=genotype_vector, cluster_groups=T, order_subgroups=T, 
cluster_groups_distance = "correlation", cluster_groups_method = "complete", cluster_patterns= T, 
cluster_patterns_distance = "correlation", cluster_patterns_method = "complete")

jacobheng/cellwrangler documentation built on Aug. 12, 2019, 6:49 a.m.