How to neglect Nan values

It looks like you already asked this question here. How is this question different?