Python SciPy FFT function - Input?
Question: I am currently writing some code which is supposed to perform FFT on a set of
data. I have a python list of points and I can easily create a time list. When
I run fft(datalist), I get the 'TypeError: 'numpy.ndarray' object is not
callable' error. I think (but please correct me) the issue is that the list is
one dimension and they have no attachment to time at all by using that one
line of code above. My question is, do I have to input a two dimensional array
with time and data points? or am I completely wrong and have to rethink?
Thanks, Mike Edit - forgot to add some code. The t=time. Could it be because
the number of entries in the array isnt equal to 2^n where N is an integer?

    
    
    sample_rate=10.00
    t=r_[0:191.6:1/sample_rate]
    S = fft([mylist])
    print S
    


Answer: The Numpy and SciPy fft functions are looking to have numpy arrays as input,
not native python lists. Also they work just fine with lengths that are not
powers of two. You probably just need to cast your list as an array before
passing it to the fft.

From your example code above try:

    
    
    from numpy.fftpack import fft
    from numpy import array
    
    """ However you generate your list goes here """
    
    S = fft(array([mylist]))
    

