Arduino / MATLAB - Servo Calibration

Interface between MATLAB and Arduino microcontroller to calibrate servo.
The Seeeduino Mega 1280 is used in this case.

Problem:
Servo does not center accurately and extends beyond 180 degrees.
Solution:
Identify error margin and apply correction in MATLAB

Resources used:
http://www.mathworks.com/matlabcentral/fileexchange/27843
http://arduino.cc/en/Reference/map