I have some data that is missing values here and there. I need to replace the NaN with zeros, as I do mathematical operations with those elements in the list named ls. I tried a list comprehension, but did not work: 
[0 if i==None else i for i in ls]  
Thanks for help/suggestions!
 
     
     
    