首页
学习
活动
专区
圈层
工具
发布
社区首页 >专栏 >gcRMA算法-聚类分析图/PCA图

gcRMA算法-聚类分析图/PCA图

作者头像
黑妹的小屋
发布于 2020-08-06 14:46:39
发布于 2020-08-06 14:46:39
1.6K0
举报

2017.12.31

>source("https://bioconductor.org/biocLite.R")

> biocLite("gcrma")

> biocLite("affycoretools")

> biocLite("graph")

> library(gcrma)

> library(graph)

> library(affycoretools)

> data("CLLbatch")

> data("disease")

> CLLgcrma<-gcrma(CLLbatch)

#使用gcrma算法预处理数据

> eset <- exprs(CLLgcrma)#提取基因表达矩阵

> pearson_cor <- cor(eset)#计算样品两两之间的pearson相关系数

>dist.lower<as.dist(1pearson_cor)#得到Pearson距离的下三角矩阵

>hc<-hclust(dist.lower,"ave")#聚类分析

> plot(hc)#聚类画图

> sampleNames <- sub(pattern = "\\.CLL",replacement = "",colnames(eset))#PCA分析

> groups <- factor(disease[,2])

>plotPCA(eset,addtext=sampleNames,gruops=groups,groupnames=levels(groups))

获取 disease数据列表

> disease

SampleID Disease

1 CLL10 <NA>

2 CLL11 progres.

3 CLL12 stable

4 CLL13 progres.

5 CLL14 progres.

6 CLL15 progres.

7 CLL16 progres.

8 CLL17 stable

9 CLL18 stable

10 CLL19 progres.

11 CLL1 stable

12 CLL20 stable

13 CLL21 progres.

14 CLL22 stable

15 CLL23 progres.

16 CLL24 stable

17 CLL2 stable

18 CLL3 progres.

19 CLL4 progres.

20 CLL5 progres.

21 CLL6 progres.

22 CLL7 progres.

23 CLL8 progres.

24 CLL9 stable

从上述列表信息可知稳定组和恶化组,从聚类分析可知,稳定组和恶化组根本就不能很好的分开,理论上,如果两组数据总体上是分开的,说明导致癌症从稳定到恶化的因素起到主导作用。如果不是,可能存在其他因素,比如个体差异。通过采用两个主成分构建分类图,可以看出稳定组(矩形)和恶化组(菱形)根本不能很好分开,在主成分分析时,考虑两个组成分的代表性以及累计贡献率,若低于60%,需要采用多维尺度分析

本文参与 腾讯云自媒体同步曝光计划,分享自微信公众号。
原始发表:2018-01-01,如有侵权请联系 cloudcommunity@tencent.com 删除
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档