Re: list of range of floats

2007-02-15 Thread Steve
On Thu, 15 Feb 2007 05:57:45 -0800, Bart Ogryczak wrote: > On Feb 14, 6:12 pm, Steve <[EMAIL PROTECTED]> wrote: >> I'm trying to create a list range of floats and running into problems. > > I've tried it the easy way. Works. > map(float,range(a,b)) Thanks Bart, I'll give it a try Steve -- htt

Re: list of range of floats

2007-02-15 Thread Bart Ogryczak
On Feb 14, 6:12 pm, Steve <[EMAIL PROTECTED]> wrote: > I'm trying to create a list range of floats and running into problems. I've tried it the easy way. Works. map(float,range(a,b)) -- http://mail.python.org/mailman/listinfo/python-list

Re: list of range of floats

2007-02-14 Thread Steve
On Wed, 14 Feb 2007 18:46:34 +, Simon Brunning wrote: > On 2/14/07, Steve <[EMAIL PROTECTED]> wrote: >> After re-reading my original post I was pretty vague. I'm trying to creat >> a list of ranges of floats, 0.0 10.0, 11 20, etc then checking to see if >> an float, example 12.5 falls in the l

Re: list of range of floats

2007-02-14 Thread Simon Brunning
On 2/14/07, Steve <[EMAIL PROTECTED]> wrote: > After re-reading my original post I was pretty vague. I'm trying to creat > a list of ranges of floats, 0.0 10.0, 11 20, etc then checking to see if > an float, example 12.5 falls in the list and if so get the list index of > where it is in the index.

Re: list of range of floats

2007-02-14 Thread Steve
On Wed, 14 Feb 2007 17:29:26 +, Simon Brunning wrote: > On 2/14/07, Steve <[EMAIL PROTECTED]> wrote: >> I'm trying to create a list range of floats and running into problems. >> I've been trying something like: >> >> a = 0.0 >> b = 10.0 >> >> flts = range(a, b) >> >> fltlst.append(flts) >> >>

Re: list of range of floats

2007-02-14 Thread [EMAIL PROTECTED]
a = 0.0 b = 10.0 inc = .2 flts = [] while a < b: flts.append(a) a += inc -- http://mail.python.org/mailman/listinfo/python-list

Re: list of range of floats

2007-02-14 Thread Larry Bates
Steve wrote: > I'm trying to create a list range of floats and running into problems. > I've been trying something like: > > a = 0.0 > b = 10.0 > > flts = range(a, b) > > fltlst.append(flts) > > When I run it I get the following DeprecationWarning: integer argument > expected, got float. H

Re: list of range of floats

2007-02-14 Thread Matimus
> fits = list(float(a) for a in range(0, 10)) Another way of writing that: flts = map(float,range(10)) -- http://mail.python.org/mailman/listinfo/python-list

Re: list of range of floats

2007-02-14 Thread Steve
On Wed, 14 Feb 2007 17:27:06 +, Dale Strickland-Clark wrote: > Steve wrote: > >> I'm trying to create a list range of floats and running into problems. >> I've been trying something like: >> >> a = 0.0 >> b = 10.0 >> >> flts = range(a, b) >> >> fltlst.append(flts) >> >> When I run it I ge

Re: list of range of floats

2007-02-14 Thread Dale Strickland-Clark
Steve wrote: > I'm trying to create a list range of floats and running into problems. > I've been trying something like: > > a = 0.0 > b = 10.0 > > flts = range(a, b) > > fltlst.append(flts) > > When I run it I get the following DeprecationWarning: integer argument > expected, got float. How c

Re: list of range of floats

2007-02-14 Thread Simon Brunning
On 2/14/07, Steve <[EMAIL PROTECTED]> wrote: > I'm trying to create a list range of floats and running into problems. > I've been trying something like: > > a = 0.0 > b = 10.0 > > flts = range(a, b) > > fltlst.append(flts) > > When I run it I get the following DeprecationWarning: integer argument >

list of range of floats

2007-02-14 Thread Steve
I'm trying to create a list range of floats and running into problems. I've been trying something like: a = 0.0 b = 10.0 flts = range(a, b) fltlst.append(flts) When I run it I get the following DeprecationWarning: integer argument expected, got float. How can I store a list of floats? TIA