Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
How to use Talib HT_SINE correctly?

I've been trying to get this to work, but I just get a list of nan - it's driving me crazy

prices = data.history(equity, 'close', 54, '1d')

HT_sine, HT_leadsine        = talib.HT_SINE(prices)  
HT_sine                     = HT_sine  
HT_leadsine                 = HT_leadsine

HT_sine or HT_leadsine always provides stuff like:

[ nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan
  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan  nan]  
1 response

Nvm. I didn't have enough data points for the sine wave.