function J = skric_lst(p0,tdata,pdata)
% Least Squares fit to Logistic Growth
N = length(tdata);
p = p0(1);
err = [pdata(1) - p];
for i = 2:N  % Logistic iteration
    p = 1.53435504*p*exp(-.000781581718*p);
    err = [err, pdata(i) - p];
end
J = err*err'; % Sum of square errors
end

