On Feb 9, 8:56 pm, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: > On Sat, 09 Feb 2008 16:44:52 -0800, nure123 wrote: > > Hi, > > > I am new to Python and would be grateful if anyone could tell me what is > > wrong with the following statement. > > > Y=array([1/S, 0*lam]) > > > where > > S=[1, 2, 3, 4] > > lam=[5, 6, 7, 8] > > Oh, a guessing game! I love guessing games. > > Let's see now... did you actually want to do a Fourier transform of some > data? > > If not, perhaps you could tell us what you expected to happen, and what > actually happened, so we can stop guessing and actually help. > > -- > Steven
I get an error like 'inconsistent shape in sequence.' I changed it to Y=array([1/S, zeros(len(lam))]) it works fine. But I am still interested in knowing why did the original programmer did not get any error whereas I got an error with the statement : Y=array([1/S, 0*lam]) -- http://mail.python.org/mailman/listinfo/python-list