These are the files that were used for the demonstrations in the webinar.
peaksObj(x)
function f = peaksObj(x)
%PEAKSOBJ casts PEAKS function to a form accepted by optimization solvers.
% PEAKSOBJ(X) calls PEAKS for use as an objective function for an
% optimization solver. X must conform to a M x 2 array to be
% valid input.
%
% Syntax
% f = peaksObj(x)
%
% See also peaks
% Copyright (c) 2012, The MathWorks, Inc.
% All rights reserved.
% Objective function
f = peaks(x(:,1),x(:,2));