Microbiome differential abundance methods produce different results across 38 datasets
https://figshare.com/articles/dataset/16S_rRNA_Microbiome_Datasets/14531724
https://github.com/nearinj/Comparison_of_DA_microbiome_methods
这个人的github主页还有其他论文的数据和代码
https://github.com/jnmacdonald/differential-abundance-analysis 这个链接有很多关于差异丰度分析的代码
今天的推文我们重复一下论文中的Figure1b
image.png
热图数据集
order_raw_count_df<-read.csv(file = "20220424/Figure1_filt_sig_counts.csv",
row.names = 1,
check.names = FALSE)
order_raw_count_df
他这里的处理方式是把数据集标准化以后映射颜色,然后添加数字标签展示真实的数据
热图数据标准化
Alpha_order_filt<-scale(order_raw_count_df,
center = TRUE,
scale = TRUE)
读取注释数据
fixed_hackathon_metadata_filt<-read.csv(file = "20220424/Figure1_filt_dataset_char.csv",
row.names = 1,
check.names = FALSE)
fixed_hackathon_metadata_filt
library(pheatmap)
pheatmap(t(Alpha_order_filt),
clustering_method = "complete",
legend=TRUE,
display_numbers=t(order_raw_count_df),
annotation_row=fixed_hackathon_metadata_filt[, c("log(Sample size)", "log(Aitch. dist. effect size)",
"Sparsity", "Richness", "Read depth variation",
"log(Read depth range)"), drop=FALSE],
annotation_legend=FALSE,
legend_labels = "% sig. features",
treeheight_col = 0,
cluster_cols = FALSE,
cluster_rows = TRUE,
main="Filtered",
angle_col=315)
image.png