There are several fitting algorithms in MATLAB. However, to do an exponential fit, you could use lsqcurvefit, using the syntax x = lsqcurvefit(fun,x0,xdata,ydata), where fun is your exponential function, x0 are your starting values. Look at the documentation from MATLAB if you get problems.