Orange Forum • View topic - Hierarchical clustering - error

Hierarchical clustering - error

A place to ask questions about methods in Orange and how they are used and other general support.

Hierarchical clustering - error

Postby Anusha » Wed Nov 06, 2013 5:11

Hi,
I m a beginner in Orange. Now I have learnt the use of KMeans in Orange and I m finding comfortable to work with it. But when i tried the basic examples of Hierarchial clustering from

http://orange.biolab.si/docs/latest/reference/rst/Orange.clustering.hierarchical/

the code is,

import Orange

iris = Orange.data.Table("iris")

matrix = Orange.misc.SymMatrix(len(iris))
matrix = Orange.distance.distance_matrix(iris, Orange.distance.Euclidean)

clustering = Orange.clustering.hierarchical.HierarchicalClustering()
clustering.linkage = Orange.clustering.hierarchical.AVERAGE
root = clustering(matrix)

root.mapping.objects = iris


I got the following error.

matrix = Orange.misc.SymMatrix(len(iris))
AttributeError: 'module' object has no attribute 'SymMatrix'


What could be the reason for this ? Should i install some dependency ? Can anyone pls help me with this.

Thanks in advance

Re: Hierarchical clustering - error

Postby Ales » Wed Nov 06, 2013 14:02

The example works fine for me. Which version of Orange are you using? You can find out by running
Code: Select all
import Orange
print Orange.version.full_version

Re: Hierarchical clustering - error

Postby Anusha » Wed Nov 06, 2013 16:00

this itself throws an error for me sayin :

NameError:name 'Orange' is not defined

I changed 'Orange' to 'orange' and then i m getting the following error

AttributeError:'str' object has no attribute 'full_version'


Return to Questions & Support



cron