ExpressionSet subsetting

◇◆丶佛笑我妖孽 提交于 2019-12-24 01:17:03

问题


I have an ExpressionSet object that I want to subset. For example,

> str(ESet)
Formal class 'ExpressionSet' [package "Biobase"] ..
  ..@ assayData        :..         
  ..@ phenoData        :
  .. .. .. ..$ STATUS  : num [1:210] 1 1 1 1 1 1 1 1 1 1 ...
  ....

I want to extract a subset where STATUS==0. I've tried:

exprs(ESet@phenoData$STATUS==0)

but it does not work.


回答1:


You are almost there. Guessing at your data structure, I think the following should work:

exprs(ESet)[ESet@phenoData$STATUS==0,]

If you look at this paper, there are lots of examples of sub-setting the data depending on strain and time. I should admit that I'm an author on this paper.



来源:https://stackoverflow.com/questions/5593931/expressionset-subsetting

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!