Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~3K People Reached
Favorite Forums

2 Posted Topics

Member Avatar for no_spam_for_dan

I happened to see (and isolate) the following problem and have 2 questions: 1) tkMessageBox is used extensively in my code. How do I make my code work without a significant re-write? 2) how do I tell the wonderful tkinter developers that there is a problem? The problem is seen …

Member Avatar for harishankar
0
191
Member Avatar for tillaart36

You could just take the average using pylab: >>> import pylab >>> grid = pylab.array[[0, 0, 0, 0, 0], [0, 1, 1, 1, 0], [0, 1, 1, 0, 0], [0, 1, 1, 1, 0], [0, 0, 0 ,0, 0]] >>> ( pylab.average(pylab.array(grid.nonzero())[1,:]), pylab.average(pylab.array(grid.nonzero())[0,:]) ) (1.875, 2.0)

Member Avatar for no_spam_for_dan
0
2K

The End.