function error = lverr(p)
%LVERR: Function defining error function for 
%example with Lotka-Volterra equations.
clear y;
lvdata
[t,y] = ode45(@lvpe,years,[H(1);L(1)],[],p);
value = (y(:,1)-H').^2+(y(:,2)-L').^2;
%Primes transpose data vectors H and L
error = sum(value);
