[Tutor] [Python 2.7] HELP: Serving HTTP on 0.0.0.0 port 80 not proceeding

2017-02-18 Thread Allan Tanaka via Tutor
Not completely sure why it doesn't open the chart on the web browser when i type this in the windows command prompt (cmd) python -m SimpleHTTPServer port 80.So first i type python ml.py data/sample.csv in cmd windows and then python -m SimpleHTTPServer port 80, but it's not proceeding to the gra

Re: [Tutor] [Python 2.7] HELP: Serving HTTP on 0.0.0.0 port 80 not proceeding

2017-02-18 Thread Alan Gauld via Tutor
Please don't repeat post. We saw it the first time. Please do post again with the extra information requested. On 18/02/17 04:46, Allan Tanaka via Tutor wrote: > Not completely sure why it doesn't open the chart on the web browser when i > type this in the windows command prompt (cmd) python -m

Re: [Tutor] Select and deselect for multiple checkboxes in Tkinter

2017-02-18 Thread Pooja Bhalode
Hi Alan, Thank you for your input. That was an easy fix to it. Thanks a lot. Pooja On Fri, Feb 17, 2017 at 8:23 PM, Alan Gauld via Tutor wrote: > On 17/02/17 18:31, Pooja Bhalode wrote: > > > I am writing to create two buttons, for selecting and de-selecting > multiple > > checkboxes that I ha

[Tutor] SciPy Optimize-like calling function as string

2017-02-18 Thread Joseph Slater
I'm trying to use the scipy.optimize code as an example to be able to avoid using *eval* to call a function named by a string. The following appears to be the code used to do this: # from scipy optimize > def wrap_function(function, args): > ncalls = [0] > if function is None: >

[Tutor] Using numpy stack functions

2017-02-18 Thread Bruhnke, Angelica
Hi, I'm new to python programming so this question will probably be a no brainer for the experienced programmer. I'm trying to create a 10x10 array of zeros and then framing it with a border of ones. Output should look like this: [[ 1. 1. 1. 1. 1. 1. 1. 1. 1. 1. 1. 1.] [ 1. 0. 0. 0. 0. 0. 0

[Tutor] Problems with matplotlib

2017-02-18 Thread Pooja Bhalode
Hi, I am trying to create a simple normal plot. But I am getting some errors which I am not able to understand. Would be a great help if someone can guide me to what I am doing wrong. Thankyou so much. Here is the code: # import matplotlib.pyplot as plt from matplotlib import pyplot as plt (Here

Re: [Tutor] SciPy Optimize-like calling function as string

2017-02-18 Thread Alan Gauld via Tutor
On 18/02/17 21:52, Joseph Slater wrote: > I'm trying to use the scipy.optimize code ... > I've seen this done with dictionaries on some pages, > but it seems that this is intended to be faster There is a saying in programming that premature optimization is the root of all evil. If you don't know

Re: [Tutor] Using numpy stack functions

2017-02-18 Thread Peter Otten
Bruhnke, Angelica wrote: > I'm new to python programming so this question will probably be a no > brainer for the experienced programmer. I'm trying to create a 10x10 array > of zeros and then framing it with a border of ones. So the final array is 12x12. > > Output should look like this: > >

Re: [Tutor] Problems with matplotlib

2017-02-18 Thread Peter Otten
Pooja Bhalode wrote: > Hi, > > I am trying to create a simple normal plot. But I am getting some > errors which I am not able to understand. Would be a great help if someone > can guide me to what I am doing wrong. > > Thankyou so much. > Here is the code: > > # import matplotlib.pyplot as plt

Re: [Tutor] SciPy Optimize-like calling function as string

2017-02-18 Thread Peter Otten
Joseph Slater wrote: > I'm trying to use the scipy.optimize code as an example to be able to > avoid using *eval* to call a function named by a string. > > The following appears to be the code used to do this: No, wrap_function wraps an existing function, adds some extra args, and provides a wa