vis.speed.fit
FIT - Fit two-dimensional Gaussian function to a speed tuning data set.
[P, SSE, R_SQUARED] = vis.speed.fit(SF, TF, R, MIN_XI, MAX_XI, ...)
Fits a Gaussian to a set of responses generated by a speed tuning curve
using a robust multi-start optimization routine to find the best-fit
parameters.
Inputs:
SF - An array of spatial frequency values.
TF - An array of temporal frequency values.
R - An array of measured responses.
MIN_XI - The lower limit for the speed index ('xi') parameter. (Default: 0)
MAX_XI - The upper limit for the speed index ('xi') parameter. (Default: 1)
Name-Value Pair Arguments:
numberStartPoints - The number of initial starting points to try. (Default: 40)
SpecificStartPoint - A 7xN matrix specifying specific starting
points to include in the search.
Outputs:
P - A 7x1 vector with the best-fit parameters.
SSE - The total sum of squared errors for the best fit.
R_SQUARED - The R-squared value (coefficient of determination).
Parameters (P):
[A, zeta, xi, sigma_sf, sigma_tf, sf0, tf0]
See also: vis.speed.fit_nospeed, lsqcurvefit