Beamline Instrument Software Support |
|
SPEC Macro documentation:
[ Macro Index |
BCU Home ]
|
SPECFITSERVER.MAC | ||||||
[ source code | installed at | configured at ] | ||||||
See other macros in category: All | ||||||
Description:
| ||||||
Documentation:
This macro set allows Spec to call the Specfit modules for peak search and fit. SETUP The name of the device server has to be given to specfitserversetup In database less mode, the server can be started as: python SpecfitServer.py That will create a TACO device server of the form: //machine.esrf.fr/SpecfitServer?5000003 To get peak search working, play first with the following configuration: fitcon["AutoFwhm"] = 0 fitcon["AutoScaling"] = 1 fitcon["Sensitivity"] = 2.5 fitcon["Yscaling"] = 1 fitcon["fitbkg"] = "Linear" fitcon["fittheory"] = "Area Gaussians" Supported theories are : "Gaussians","Lorentz","Area Gaussians", "Area Lorentz","Pseudo-Voigt Line","Area Pseudo-Voigt","Step Down", "Step Up","Slit","Hypermet" Supported backgrounds are : "Constant","Exponential","Linear","Internal" | ||||||
Macros:
Usage: specfitserversetup [specfitdevicename] Set the variable SPECFIT_DEV and set the device server in mode "tcp" specfitservergetconf Usage: specfitservergetconf (specfitdevicename) Give back an associative array with the FULL specfit configuration specfitserversetconf Usage: specfitserversetconf (specfitdevicename,configuration) Configure the keys of the associative array configuration recognized by the device server. specfitserversearch Usage: specfitserversearch (specfitdevicename,two_col_array) Perform a quick estimation of two_col_array and gives back an associative array with the form: tmp[0] = Number of peaks tmp[1] = Position_1 tmp[2] = Position_2 ... tmp[n] = Position_n specfitserverfit Usage: specfitserverfit (specfitdevicename,two_col_array) Perform a quick estimation of two_col_array and gives back an associative array with the form: tmp[0] = Number of parameters tmp[1] = Name of parameter 1 tmp[2] = Value of parameter 1 ... tmp[n] = Value of parameter n specfitserver_fitscan Usage: specfitserver_fitscan (specfitdevice,counter,parameters) fit the last scan on "counter" and return the fit result. If no fit parameters are given the default values are: fitcon["AutoFwhm"] = 0 fitcon["AutoScaling"] = 1 fitcon["Sensitivity"] = 2.5 fitcon["fitbkg"] = "Linear" fitcon["fittheory"] = "Area Gaussians" specfitserver_plotfitscan Usage: specfitserver_plotfitscan (specfitdevice,counter,parameters) fit the last scan on "counter" plot the fitted data then return the fit result. If no fit parameters are given the default values are: fitcon["AutoFwhm"] = 0 fitcon["AutoScaling"] = 1 fitcon["Sensitivity"] = 2.5 fitcon["fitbkg"] = "Linear" fitcon["fittheory"] = "Area Gaussians" fitnow Usage: fitnow fit the last scan, return the fit data and plot the fitting curve. fitgaussians Usage: fitgaussians fit the last scan, return the fit data and plot the fitting curve. fitlorentz Usage: fitlorentz fit the last scan, return the fit data and plot the fitting curve. fitpvoigt Usage: fitpvoigt fit the last scan, return the fit data and plot the fitting curve. fitslit Usage: fitslit fit the last scan, return the fit data and plot the fitting curve. fitstepup Usage: fitstepup fit the last scan, return the fit data and plot the fitting curve. fitstepdown Usage: fitstepdown fit the last scan, return the fit data and plot the fitting curve. fithypermet Usage: fithypermet fit the last scan, return the fit data and plot the fitting curve. specfitservergetestimate Usage: specfitservergetestimate (specfitdevicename) Give back an associative array with the FULL specfit configuration specfitserversetestimate Usage: specfitserversetestimate (specfitdevicename,configuration) Configure the keys of the associative array configuration recognized by the device server. specfitservergetconstraints Usage: specfitservergetconstraints (specfitdevicename) Give back an associative array with the FULL specfit configuration specfitserversetconstraints Usage: specfitserversetconstraints (specfitdevicename,configuration) Configure the keys of the associative array configuration recognized by the device server. | ||||||
Internal Macros: | ||||||
Usage: fitgaussian fitgauss Usage: fitgauss fitvoigt Usage: fitvoigt fitforcedgaussian Usage: fitforcedgaussian Force a single gaussian fit taken SPEC parameters as starting parameters. Return the fit data and plot the fitting curve. _fitforcedgaussian Usage: _fitforcedgaussian(specfitdev,yourdata,parameters,constraints0) | ||||||
|