Check that the log ratio is finite before using it