title: Replacing all NaNs with zeros without looping through the whole matrix?
body: <p>I had an idea to replace all the NaNs in my matrix by looping through each one and using isnan. However, I suspect this will make my code run more slowly than it should. Can someone provide a better suggestion?</p>