TANHFIT-Fitacurvewithahyperbolictangenttanh[FIT_CURVE,PARAMS,GOF,FITINFO]=vlt.fit.tanhfit(X,Y,...)Findsa,b,c,dsuchthattheerrorintheequationY=a+b*TANH((X-c)/d)isminimizedintheleast-squaressense.
FIT_CURVEisafitcurvethatis100x2(bydefault,seebelow)whereFIT_CURVE(:,1)is100equallyspacedpointsbetweenmin(X)andmax(X),andFIT_CURVE(:,2)istheresultofthefit.]
PARAMSistheparametersreturnedfromMatlab's FIT function. This function also takes additional parameters in the form of name/value pairs. Parameter (default) | Description --------------------------------------------------------------- NPTS_CURVE (100) | Number of points to produce in the fit a_range [-Inf Inf] | Search range for fit parameter a b_range [0 Inf] | Search range for fit parameter b c_range [-100 100] | Search range for fit parameter c d_range [1e-12 Inf] | Search range for fit parameter d startPoint [0 1 0 1] | Starting point for the search Jason Osik 2016-2017 See also: FIT, FITTYPE