hcluster

    3熱度

    1回答

    我使用模塊hcluster從距離矩陣計算樹狀圖。我的距離矩陣是這樣生成的數組的數組: import hcluster import numpy as np mols = (..a list of molecules) distMatrix = np.zeros((10, 10)) for i in range(0,10): for j in range(0,10):

    5熱度

    2回答

    我必須通過運行創建載體列表: import hcluster import numpy as np from ete2 import Tree vecs = [np.array(i) for i in document_list] 其中document_list是網頁文件,我分析的集合。然後我進行聚類: Z = hcluster.linkage(vecs, metric='cosine

    0熱度

    1回答

    我想運行下面的代碼,並且得到一個AttributeError:'module'對象沒有在最後一行中引發的屬性'hcluster'。 我在Mountain Lion中運行,我使用pip和自制軟件,而hcluster在PYTHONPATH =/usr/local/lib/python2.7/site-packages中。 任何想法可能會出錯?謝謝。 import os import hcluster

    10熱度

    1回答

    我正在用相關距離度量(即1-皮爾森相關)對2維矩陣進行層次聚類。我的代碼如下(該數據在一個名爲「數據」變量): from hcluster import * Y = pdist(data, 'correlation') cluster_type = 'average' Z = linkage(Y, cluster_type) dendrogram(Z) 我得到的錯誤是: ValueE

    0熱度

    1回答

    我使用與hcluster提供下列行的setup.py文件安裝hcluster補充說: sys.path.append("c:\\Program Files\\Python26\\Lib\\site-packages\\hcluster-0.2.0") sys.path.append("c:\\Program Files\\Python26\\Lib\\site-packages\\hcluste

    2熱度

    1回答

    我從http://pypi.python.org/pypi/hcluster下載hcluster,然後解壓縮到一個文件夾,然後鍵入"python setup.py install"。這似乎爲它確定顯示: Z:\>python setup.py install running install running build running build_py running build_ext