Re: [Tutor] python clusters

2011-04-14 Thread Luc Kesters
When you say "text file" and variables, you mean you have a file with n records and m fields? Isn't the following what you are searching for? http://docs.scipy.org/doc/scipy/reference/cluster.html___ Tutor maillist - Tutor@python.org To unsubscribe or

[Tutor] how to develop a python exe file in windows using python3.1

2011-04-14 Thread ema francis
I am using python3.1 in windows environment.How can I create a python executable file? I tried with py2exe package but it is not compatible with python3.1.Is there any other way... pls help me... ___ Tutor maillist - Tutor@python.org To unsubscribe or c

Re: [Tutor] how to develop a python exe file in windows using python3.1

2011-04-14 Thread James Reynolds
We literally just answered this question a couple days ago, but if you need to make an executable in 3.1, CX freeze i believe should work. On Thu, Apr 14, 2011 at 9:42 AM, ema francis wrote: > I am using python3.1 in windows environment.How can I create a python > executable file? > I tried with

Re: [Tutor] Need help with the property function

2011-04-14 Thread Jim Byrnes
Steven D'Aprano wrote: Jim Byrnes wrote: I'm trying to teach myself OOP in python (again). The following code from Dawson's book runs fine, unaltered [1]. What's Dawson's book? Python Programming for the absolute beginner, by Michael Dawson Thanks for the explanation. It was exactly wit

Re: [Tutor] Need help with the property function

2011-04-14 Thread Jim Byrnes
Dave Angel wrote: On 01/-10/-28163 02:59 PM, Jim Byrnes wrote: I'm trying to teach myself OOP in python (again). The following code from Dawson's book runs fine, unaltered [1]. class Critter(object): """ A virtual pet """ def __init__(self, name): print "A new critter is born" self.name = name

[Tutor] super() with Multiple Inheritance

2011-04-14 Thread James Thornton
Why does user.params() not return all the params up the inheritance chain? -- It's not including the params defined in Person() -- notice Vertex() does not have a params() method. class Element(object): def __init__(self,element_type): self.oid = None self.uuid = uuid.uuid4()

Re: [Tutor] python clusters

2011-04-14 Thread nookasree ponamala
Thank you very much. This is exactly what I'm looking for. Do I have to install numpy and Scipy? It throws an error No module named numpy.   I'm completely new to Python programming, trying to convert SAS code to python. I am able to do some simple steps, but this one is the clustering program in

Re: [Tutor] python clusters

2011-04-14 Thread Alan Gauld
"nookasree ponamala" wrote ...trying to convert SAS code to python. this one is the clustering program in SAS enterprise miner OK, I tried Google and got a 3Meg SAS PDF file that didn't help much. :-( I'm curious. Could someone post the elevator pitch on SAS Clustering? What on earth

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread Alan Gauld
"James Thornton" wrote Why does user.params() not return all the params up the inheritance chain? -- It's not including the params defined in Person() -- notice Vertex() does not have a params() method. class Element(object): def params(self): return dict(uuid=self.uuid, key=se

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread James Thornton
I found this issue -- I was setting setting self.s to the return value of super() and trying to use self.s in params(): self.s = super(User,self) self.s.__init__(name,uri,email) def params(self): params = dict(name=self.name) params.update(self.s.params()) ...but this won't work.

Re: [Tutor] python clusters

2011-04-14 Thread nookasree ponamala
Here is the link which explains Clustering in SAS clearly. Copy and paste it in browser. http://www.hstathome.com/tjziyuan/SAS%20Data%20Mining%20Using%20Sas%20Enterprise%20Miner%20-%20A%20Case%20Study%20Appro.pdf Sree. --- On Thu, 4/14/11, Alan Gauld wrote: > From: Alan Gauld > Subject: Re:

Re: [Tutor] Python on TV

2011-04-14 Thread Bill Allen
Same here. I did not realize I was living in an internet censored country here in Texas! On Mon, Apr 11, 2011 at 16:04, bob gailer wrote: > On 4/11/2011 4:20 PM, Alan Gauld wrote: > >> I've just watched the Channel 5 programme "The Gadget Show" >> where the presenters set a new Guinness worl

Re: [Tutor] how to develop a python exe file in windows using python3.1

2011-04-14 Thread Bill Allen
On Thu, Apr 14, 2011 at 08:42, ema francis wrote: > I am using python3.1 in windows environment.How can I create a python > executable file? > I tried with py2exe package but it is not compatible with python3.1.Isthere > any other way... > pls help me... > > cxfreeze works quite well for produci

Re: [Tutor] Python on TV

2011-04-14 Thread Luke Paireepinart
I don't see how a content provider preventing you from accessing content internationally that they probably don't have international distribution rights to as censorship. It's not like your ISP is blocking your access. - Sent from a mobile device. Apologies for brevit

Re: [Tutor] Python on TV

2011-04-14 Thread Joel Goldstick
On Thu, Apr 14, 2011 at 4:25 PM, Bill Allen wrote: > Same here. I did not realize I was living in an internet censored country > here in Texas! > > > > > On Mon, Apr 11, 2011 at 16:04, bob gailer wrote: > >> On 4/11/2011 4:20 PM, Alan Gauld wrote: >> >>> I've just watched the Channel 5 program

Re: [Tutor] Python on TV

2011-04-14 Thread Bill Allen
On Thu, Apr 14, 2011 at 15:33, Luke Paireepinart wrote: > I don't see how a content provider preventing you from accessing content > internationally that they probably don't have international distribution > rights to as censorship. It's not like your ISP is blocking your access. > > Seriously, I

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread Alan Gauld
"James Thornton" wrote I found this issue -- I was setting setting self.s to the return value of super() and trying to use self.s in params(): ...but this won't work. No, because super returns whatever the superclass method returns. Which in init() is usually None. You have to use supe

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread Steven D'Aprano
James, Your subject line is misleading: you ask about *multiple* inheritance, but the code you use is *single* inheritance: object -> Element -> Vertex -> Person -> User Multiple inheritance occurs when you have a class that inherits from two or more parent classes: cla

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread Steven D'Aprano
Alan Gauld wrote: "James Thornton" wrote I found this issue -- I was setting setting self.s to the return value of super() and trying to use self.s in params(): ...but this won't work. No, because super returns whatever the superclass method returns. Which in init() is usually None. No

Re: [Tutor] super() with Multiple Inheritance

2011-04-14 Thread Alan Gauld
"Steven D'Aprano" wrote No, because super returns whatever the superclass method returns. Which in init() is usually None. No, super returns a proxy object that encapsulates knowledge of the superclasses of the argument (usually "self", but not necessarily). >>> b = B() >>> s = super(B, b

Re: [Tutor] Python on TV

2011-04-14 Thread Steven D'Aprano
Luke Paireepinart wrote: I don't see how a content provider preventing you from accessing content internationally that they probably don't have international distribution rights to as censorship. It's not like your ISP is blocking your access. There is nothing about censorship that means it c

[Tutor] Writing to the file system and verify the files written out.

2011-04-14 Thread Becky Mcquilling
Hi, all: I'm doing a tutorial online and I have run across an assignment to write a unit test. One of the tests is working fine, the other one is failing. The goal of this particular one is: 1) Create a directory 2) Create files in the directory that are listed in the text files 3) Crea