[regression] some more files

This commit is contained in:
2020-12-21 21:33:13 +01:00
parent f5c3bb6139
commit f6b52d32cb
7 changed files with 14 additions and 14 deletions

View File

@@ -34,7 +34,7 @@ function gradmse = meanSquaredGradient(x, y, func, p)
ph = eye(length(p))*h; % ... for each parameter
mse = meanSquaredError(x, y, func, p);
for i = 1:length(p) % for each coordinate ...
msepi = meanSquaredError(x, y, func, p + ph(:,i));
msepi = meanSquaredError(x, y, func, p(:) + ph(:,i));
gradmse(i) = (msepi - mse)/h;
end
end