如果大多数基因列表中存在,如何保留基因?
我有9个基因列表,每个基因的长度为2000个基因。我想保留基因在6个或更多列表中。我不确定如何指定这一点,我一直在使用Intersect函数。
任何帮助都将受到赞赏。
I have 9 gene lists, each 2000 genes in length. I want to keep genes if present in 6 or more of lists. I am not sure how to specify this, I have been using the intersect function.
Any help is appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
首先,使用少量辅助功能重新创建数据:
然后提取唯一元素:
在这里,我们可以检查合成数据是否具有一定的冗余:
然后在计数发生时迭代在唯一的基因和列表上:
然后获取常见基因:
First, recreate the data with a little helper function:
Then extracts the unique elements:
Here we can check that the synthetic data have some redundancy:
Then iterate over unique gene and list while counting occurences:
Then get the common genes: