Adding perl script for endpoint error calculation