cluster_expr_report: 生成各个cluster的Heatmap以及boxplot

Description Usage Arguments Value

View source: R/Cluster_Expr.R

Description

依据stat_by_cluster生成的list数据,生成 1)heatmap1:指定cluster中,各个样本中的marker的表达情况 2)heatmap2:指定cluster中,各个样本中的marker与对照的相对强度(Arcsinh raitio) 3)boxplots:统计各marker在该cluster中的表达

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
cluster_expr_report(
  cluster_stat,
  cluster_id = NULL,
  color_cond = NULL,
  subgroup_cond = NULL,
  group_colorset = brewer_color_sets,
  output_dir = "Cluster_expr_report(heatmap and boxplot)",
  heatmap_ctrl = NULL,
  heatmap1_trans_method = "simpleAsinh",
  heatmap1_color = colorRampPalette(c("black", "yellow")),
  heatmap2_color = colorRampPalette(c("blue", "white", "red")),
  Rowv = T,
  Colv = F,
  dendrogram = "row",
  show_pvalues = TRUE,
  hide_ctrl = NULL,
  comparisons = NULL,
  comparisons.stat.paired = NULL,
  comparisons.stat.method = NULL,
  groups_to_show = NULL,
  stat.paired = NULL,
  stat.method = NULL,
  set.equal.var = NULL,
  conf.level = NULL,
  p.adjust.method = NULL
)

Arguments

cluster_stat

stat_by_cluster()函数生成的list数据

cluster_id

指定输出cluster的id,例如:如果要输出前五个cluster,cluster_id=c(1:5); 如果要输出全部cluster,保持其默认值NULL即可。

color_cond

指定boxplot依据哪个条件进行着色

subgroup_cond

指定heatmap_ctrl对应的分组

group_colorset

boxplot采用的配色方案:默认 brewer_color_sets, 也可以选择其他公开生成色阶的函数例如 rainbow等

output_dir

输出数据文件夹名称

heatmap_ctrl

在major_cond中选择一个(或多个)在Heatmap中显示做为control的组名,例如"A_Tumor"

heatmap1_trans_method

数据转化方式,有五种: "CytofAsinh",CytofAsinh转换所有表达数据; "simpleAsinh",simpleAsinh转换所有表达数据,(公式为asinh(x/5)),这是默认设置; "0_to_Max",所有Marker的信号强度除以最大值,线性转换,通过除以各通道信号的最大值把数值scale到0~1; "Min_to_Max",线性转换,最小值转换成0,最大值转换成1,最大限度展现population的表达差异; "simpleAsinh_0_to_Max" 先Arcsinh转换,然后除以各通道信号的最大值把数值scale到0~1范围内; "simpleAsinh_Min_to_Max" 先Arcsinh转换,然后最小值转换成0,最大值转换成1,最大限度展现population的表达差异;

heatmap1_color

设置Arcsinh expression heatmap的colorbar

heatmap2_color

设置Arcsinh ratio heatmap的colorbar

Rowv, Colv

逻辑变量,分别heatmap设定行和列是否聚类

dendrogram

显示heatmap行或者列的树形图,"both","row","column","none"

show_pvalues

逻辑变量,TRUE或者FALSE,决定是否在图上显示p Value

hide_ctrl

在图片中隐藏对照组(仅用于多个ctrl的情况)

comparisons

list变量,用来指定需要显示p值的组别,例如list(c("PBMC","Biopsy"),c("PBMC","Tumor"))就是要分别显示PBMC与Biopsy和Tumor两组之间的p值;如果comparisons=NULL,则显示各组与对照组的p值

comparisons.stat.paired

逻辑变量,TRUE或者FALSE,表示comparisons是否是成对检验

comparisons.stat.method

指定组别的p值计算方法

如使用统计默认参数,以下参数无需设置

groups_to_show

想要展示部分组时,指定展示组的组名,默认为NULL,展示所有组

stat.paired

逻辑变量,TRUE或者FALSE,表示是否是成对检验

stat.method

一个字符串,指定统计分析的方法,取值有三种:"auto",“t-test",“wilcox-test”,当取值为"auto"时,即为测试模式,会对数据进行正态分布和方差齐性测试,自动选择适合的统计方法,为正式分析过程中的统计方法选择提供依据。

set.equal.var

一个字符串,指定方差齐性,取值有三种:"TRUE","FALSE"(默认),"auto",选择"auto"时即可以进行方差齐性测试;

conf.level

显著性水平,默认0.95,(即p<0.05为显著)

p.adjust.method

对p值进行校正的方法:"BH"(默认,推荐) "holm", "hochberg", "hommel", "bonferroni","BY","fdr", "none"

Value

none


XinleiChen001/cytofexplorer documentation built on Oct. 31, 2020, 5:59 p.m.