fixed division by zero bug if nreturned=0 for nscanned/n plot.