When taking the log of a specific column within a numpy array, i.e., logSFROIIdC = np.log(data_dC[:, 9]) the compiler returns the error:
-c:13: RuntimeWarning: divide by zero encountered in log.
Now, I know why this happens, i.e., log(-1) = Math Error.
However, I want to be able to call something or write some code which then skips any value in the array which would cause this error, then ignoring that row altogether. Allowing that data column to be usable again.
I have tried various methods and this is a last resort asking the community.
data_dC[:, 9]the right format?warningmodule.