Changed errplot to make it work in Mac OS 10.8.5