我怎么能够(就基因表达数据而言)以显示基因表达价值矩阵和分图的方式,在 Python进行分级分类? 我这里指的是:
在第6点(图1)之后显示,该图被划入基因表达矩阵的左侧,这些行经重新排列以反映集群。
我怎么能利用 n、sc或其他工具来做到这一点? 此外,用大约11 000种基因的矩阵来计算是否可行,使用滑坡距离作为衡量尺度?
EDIT:许多人提出了组合式包裹,但我仍然不敢确定如何绘制我与Talhury有关的形象。 例如,我怎么能够使用马塔普图利,在加热图矩阵的同时,超标?
感谢。
我怎么能够(就基因表达数据而言)以显示基因表达价值矩阵和分图的方式,在 Python进行分级分类? 我这里指的是:
在第6点(图1)之后显示,该图被划入基因表达矩阵的左侧,这些行经重新排列以反映集群。
我怎么能利用 n、sc或其他工具来做到这一点? 此外,用大约11 000种基因的矩阵来计算是否可行,使用滑坡距离作为衡量尺度?
EDIT:许多人提出了组合式包裹,但我仍然不敢确定如何绘制我与Talhury有关的形象。 例如,我怎么能够使用马塔普图利,在加热图矩阵的同时,超标?
感谢。
Many clustering methods including scipy.cluster
start by sorting all pairwise distances,
~ 60 million in your case, not too big.
How long does the following take for you ?
import scipy.cluster.hierarchy as hier
import pylab as pl
def fcluster( pts, ncluster, method="average", criterion="maxclust" ):
""" -> (pts, Y pdist, Z linkage, T fcluster, clusterlists)
ncluster = n1 + n2 + ... (including n1 singletons)
av cluster size = len(pts) / ncluster
"""
pts = np.asarray(pts)
Y = scipy.spatial.distance.pdist( pts ) # ~ N^2 / 2
Z = hier.linkage( Y, method ) # N-1
T = hier.fcluster( Z, ncluster, criterion=criterion )
# clusters = clusterlists(T)
return (pts, Y, Z, T)
hier.dendrogram( Z )
How to permute the matrix and plot nicely was asked here in So in March, with a partial answer.
http://docs.scipy.org/doc/scipy/vis/cluster.hierarchy.html“rel=“nofollow noreferer”>cluster.hierarchy 模块。 指挥实际上甚至非常相似。 但是,您将不得不使用<代码>更正而不是corr
作为pdist
,而不是cluster
的参数。 功能组别模块的名称为fcluster
。 另外,对于目录而言,功能是dendrogram
in scipy,而不是clustergram
in Matlab。
您可以肯定地使用电子幻灯测量仪(认为是<代码>pdist的缺失)。 我认为,用11 000个基因进行这项工作是可行的,因为这将是11000*(11000-1)/2=60494 500(11,000)选择计算距离。 这个数字很多,但我认为肯定是可行的。
两人在利用幻灯和校正制作分级和热图图像化原型模块方面取得了一些适当的进展:
我现在正在调整这一法典,以形成一个完整的等级组合模块,我可以把这一模块纳入我的记录稿件之一。 我对最终产品感到非常高兴,最终产品将使用各种集束测量仪和方法以及彩色梯度制作热图。 守则和实例产出如下:
http://altanalyze.blogspot.com/2009/06/hierarchical-clustering-heatmaps-in.html
Is there a way to force Django models to pass a field to a MySQL function every time the model data is read or loaded? To clarify what I mean in SQL, I want the Django model to produce something like ...
I am looking for an enterprise tasks scheduler for python, like quartz is for Java. Requirements: Persistent: if the process restarts or the machine restarts, then all the jobs must stay there and ...
Given the following list that contains some duplicate and some unique dictionaries, what is the best method to remove unique dictionaries first, then reduce the duplicate dictionaries to single ...
Simple enough question: I m using python random module to generate random integers. I want to know what is the suggested value to use with the random.seed() function? Currently I am letting this ...
I m using PyDev under Eclipse to write some Jython code. I ve got numerous instances where I need to do something like this: import com.work.project.component.client.Interface.ISubInterface as ...
Python s paster serve app.ini is taking longer than I would like to be ready for the first request. I know how to profile requests with middleware, but how do I profile the initialization time? I ...
Our business currently has an online store and recently we ve been offering free specials to our customers. Right now, we simply display the special and give the buyer a notice stating we will add the ...
I m trying to convert a Python dictionary into a Python list, in order to perform some calculations. #My dictionary dict = {} dict[ Capital ]="London" dict[ Food ]="Fish&Chips" dict[ 2012 ]="...