how to do a non-linear multi-variate regression

Hello, can I get some input on how to perform a multiple variate regression in Igor? I am using a customized fitting function, non-linear and two to three variables. In the CurveFit panel thought, only X and Y variables are listed, could not find an option for a third variable. Thanks!!

johnweeks

Since the format of a user-defined fitting function requires an input for each independent variable, if you sometimes fit two, and other times three, you will need two fitting functions.

Be sure to use the "FitFunc" function type keyword on your fitting function:

Function threeIndVars(pw, xx, yy, zz) : FitFunc
	WAVE pw
	Variable xx, yy, zz

	etc.
	return ...
end