How to test this matlab script

Please, I would like to test the following script.
It seems to work, but I do not know how to check the result.

These are the input data.

xdata = [0.9 1.5 13.8 19.8 24.1 28.2 35.2 60.3 74.6 81.3]& # 39 ;;
ydata = [455.2 428.6 124.1 67.3 43.2 28.1 13.1 -0.4 -1.3 -1.5]& # 39 ;;
list = [xdata, ydata];

Script file

a function [pax, pay] = extract_parameter (list)

options.Algorithm = levenberg-marquardt & # 39 ;;

m_start = [0; 0];
fun = @ (x) in_func (list, x);
    [parameter, ~] = lsqnonlin (fun, m_start,[],[], options);

pax = parameter (1);
pay = parameter (2);

% Nested function
fun function = in_func (list, x)
m_vel = list (:, 1);
m_ang = list (:, 2);
fun = m_vel + x (1) * cos (m_ang) + x (2) * sin (m_ang);
end
end

The expected parameters pax and pay are calculated.
I have to replace them in the original function at x (1) and x (2) and check the result.
Please, could someone help me check it?