Warning: This program is not maintained anymore. In the near future, it will be removed from the set of GIPSY tasks. An improved version with graphical user interface is called XGAUPROF. Program: profit Purpose: Interactive fitting of one-dimensional profiles Category: PROFILES, PLOTTING File: profit.c Author: P.R. Roelfsema (M. Vogelaar) Keywords: STARTNEW= Start improved version of this program? [Y]/N A new version with graphical user interface is called XGAUPROF. You can start it here. **STOP= Stop processing? [N] **NEXT= Process next profile? [N] INSET= Name of input data set and subsets [quit] BOX= Give area for processing [entire map] POS= Give position for profile to process [center of map] This keyword allows you to go to a new position for fitting. Giving POS=Q will stop the program. **GRIDS= Plot the grids ? [N] **ZERO= Plot the zero level ? [N] GRDEVICE= Give plot device [list all plotdevices] Next loop; FIT= Give type of function to fit [same as before] Here you can specify a function name and, if appropriate the number of components to use; FNAME . P(OLY) N - an N-th order polynomial G(AUSS) N - an N-component guassian V(OIGT) N - an N-component voigt profile GUESS0= Give a guess for the zero-level [0] This keyword is asked only when appropriate e.g. for a GAUSS fit. GUESSn= Give guess of ... for FNAME fit [ ... ] Give values for the different fit parameters as relevant for FNAME. If you specified a parameter to be fixed in the fit, the guess will be taken as the value. FIX= Give parameters to fix in fit. Specify which parameters of the fit should be kept fixed at the value given using the GUESSn= keywords. Possibilities: POLY - none GAUSS - BASE, AMP1, CENTER1, FWHM1, AMP2, CENTER2 etc. VOIGT - BASE, AMP1, CENTER1, FWHM1, LOR1, AMP2, CENTER2 etc. **xxxLIM= Give limits for xxx in fit [none] e.g. BASELIM=-10 10 implies that the fitted base level should be between -10 and +10. If the baselevel is found outside that range, the fit is considered to be BAD. Other keywords are e.g. AMP1LIM=, CENTER1LIM= etc. MODE= Which mode? 1-inter, 2-semi, 3-auto [1] This keyword is asked only once, after that it becomes a hidden keyword, and can be specified at any time during the loop through different positions. SN= Give minimum acceptable signal-to-noise ratio [3] Fits in which any of the fitted parameters have a formal signal to noise ratio less than SN will be considered bad. As a result the output map(s) will contain undefined values for the profile. JUDGE= GOOD/BAD and NEXT profile, profile AGAIN, MORE fits, or SUBTRACT. Give a judgement on the fit; is it GOOD or BAD, and tell what to do next; go to the NEXT profile, do MORE fits or SUBTRACT this fit. The default for GOOD/BAD depends e.g. on the SN criterion specified above. The default for what next is NEXT. Note, for all commands the first character suffices. Entering QUIT will cause the program to stop. POS= Give position for profile to process [next pixel] CUTM= Give cutoff level to use in mask set [no mask set] MASKSET= Give set to use for mask **CONT= Is this continuation of previous run? [N] If CONT=N the output sets are set to undefined, if you want to continue a previous run of PROFIT use CONT=Y PARSET= Give setname to save parameters [don't save parameters] ERRSET= Give setname to save errors [don't save errors] MODSET= Give setname to save fitted models [don't save] RESSET= Give setname to save residuals [don't save residuals] **STOP= Stop processing? [N] **MODE= Which mode? 1-inter, 2-semi, 3-auto [1] **TOL= Give tolerance of fit [0.001] **LAB= Give mixing parameter of fit [0.01] **NITER= Give maximum nr. of iterations of fit [25] **GRDEVICE= Give plot device [list all plotdevices] **FRAMECOL= Give color for frame [8 (i.e. orange)] For possible colors see below. **DATA= Give line-type, thickness, symbols and color for plot of data **GUES= Give line-type, thickness, symbols and color for plot of guesses **MOD= Give line-type, thickness, symbols and color for plot of model **RES= Give line-type, thickness, symbols and color for plot of residual These four keywords define what your plot looks like. They should be answered with three numbers ,,, where - line type; 0-5 0 - no line 1 - solid line 2 - dashed line 3 - dot-dash-dot-dash line 4 - dotted line 5 - dash-dot-dot-dot line - line thickness; 0 - 201 dots/line - symbol number; 0 - 31 0 - no symbol 1 - small dot 2 - plus 3 - star 4 - circle 5 - cross 6 - square 7 - triangle 8 - circle/plus 9 - cricle/dot 10 - 4-star 11 - diamond 12 - open star 13 - filled trian. 14 - open plus 15 - jew-star 16 - filled square 17 - big dot 18 - filled star 19 - large square 20-27 various size circles 28 - left arrow 29 - right arrow 30 - up arrow 31 - down arrow - color number; 0 - 15 for GRDEVICE=GIDS 0 - background 1 - default 2 - red 3 - green 4 - blue 5 - cyan 6 - magenta 7 - yellow 8 - orange 9 - green + Yellow 10 - green + Cyan 11 - blue + Cyan 12 - blue + Magenta 13 - red + Magenta 14 - dark Gray 15 - light Gray By specifying e.g. MOD=0 0 0 0 the model will not be drawn in the plot. Updates: Aug 19, 1991: PRR, Document created. Nov 9, 1992: PRR, Finishing it off; added colors, WINDOW=, FIX=, JUDGE=, MNMX on output sets, **LIM=. Nov 26, 1992: PRR, Voigt function Sep 26, 1993: PRR, More digits in screen output Larger data arrays Made xxxLIM hidden keyword Changed use of MODE= Dec 20, 1994: KLO (Olaf K.) Secondary axis problem solved. Program recognizes permutated axes for 'COTRANS' Mar 10, 1995: PRR Fixed problem with FIX= keyword: program now allows FIXing multiple parameters. Apr 17, 1996: VOG Several minor bugs removed Jun 12, 1996: VOG Initialize local 'err' arrays, because PROFIT crashed on alpha machines.