proFit
Macintosh application for data/function analysis, plotting, and curve fitting.

It is used by scientists and engineers to analyze their measurements and the mathematical models they use to describe them


In this article
New features

Numerics Command

Debug window

Other information
Screenshot

System Requirements

Other programs of Statistics

How to Order

New features

New User Interface Experience and better integration with Mac OS 9.0
• "Open" and "Save" dialog boxes now use the new "navigation manager" routines.
• Hold down the command-key and click on a window title to find out where the file belonging to the window is.
• Click the document icon appearing to the left of a window title and drag it anywhere you want in a Finder window to move your document to a new location.
• Live feedback when resizing columns and info field in data windows.
• Proportional scrollbars.
• Text and data files now store the current selection.
• All windows and tool palettes use the current system appearance.

• The status window appearing during fitting is now resizeable when it contains a list of parameters.
• All Dialog boxes and Alert boxes are movable.
• The "Check for update" button in the "about pro Fit" box can be used to find out if a newer version of pro Fit is available.

Date and Time data
pro Fit 5.5 understands and works with time data, i.e. absoulte calendar dates and relative time. There are new column formats in data windows for date&time and relative-time data, and date and time data can be used in data-transforms, graphs, and by user-defined programs and functions.

Technical information
The Mac OS stores dates as the number of seconds since January 1, 1904 (for the technically minded, the date is stored as an integer number, 8 byte long).
pro Fit uses the same convention as the Mac OS to store dates, but uses "double" floating point values instead of integers. With this number representation, pro Fit can store and recognize dates with second precisions until up to 1015 (this corresponds more or less to a 6 byte long integer) seconds after January 1, 1904. pro Fit can store dates with second-precision up to 31 million years in the future, and it can store dates with day-of-the-week precision up to 3.1 billion years (3 x 109) in the future.
However, the date-time conversion routines currently available in Mac OS 9 only support dates up to 29'940 AD for date-to-string conversions, date-calculations, etc. Up to this limit, pro Fit can store dates with a precision of milliseconds, while it can store dates in the present with a precision of approximately a microsecond.

Preview Window
The preview window has been redesigned. It is now resizeable, and many more options, like the color of the function curve, its thickness, or the size of data points, are user-selectable (see Screenshot).

Parameter Window
The parameter window has been redesigned, and now supports up to 128 parameters (see Screenshot). It is now possible to paste some parameter values selectively into consecutive parameter value fields by selecting a parameter and pasting tab-separated values.

Predefined functions
The predefined function Spline has more options that can be set by clicking the "Spline Settings" button in the parameter window. There is a new possibility to define the spline curve by using function parameters to set the coordinates of the points on which it is based. This allows, e.g., to fit a Spline function to some set of noisy points, in order to get a smooth guide-to-the-eyes curve. When doing this, be careful not to choose too many points for the Spline-definition.

Data Windows
• Column-calculations can be stored and made permanent. They will be executed automatically whenever data is changed in a data window. The instruction for calculating a "calculation-column" can be changed via the column format dialog box, or can be generated via the command "Data Transform".
• Text columns can be used for sorting.
• Sorting keeps the order of rows when they correspond to equal values in the sort-column. This allows to sort by more than one column, by using the sort command multiple times.
• The index column in data windows can be set to the default X or Y column.
• New data column types and formatting options for date & time, and relative time data.

Drawing Windows
• New Save and Open possibilities for JPEG and PICT files, as well as saving of (uncompressed) GIF files. Anti-aliasing is supported when saving drawings as GIF or JPEG.
• Some small problems connected with EPS files have been fixed.
• Undo now restores the selection.
• Command clicking for viewing graph coordinates now also works for grouped graphs.
• Lines, Polygons, and Rectangles can be rotated by any angle, not just multiples of 90 degrees. The "Coords" window displays the current angle, which can be edited to change the orientation of a shape. The Rotate Command in the Draw Menu has an "Other..." item that can be used to specify relative rotations of any number of degrees.
• Drawing shapes have properties that can be read and modified using the calls GetShapeProperty and SetShapeProperties, respectively.

New drawing objects, or shapes
You can now create "control shapes" in drawing windows, such as buttons, checkboxes, radio buttons, popup menus, static texts and edit fields. These new control shapes can be used to create custom interfaces for user-defined programs by switching a drawing window from its normal state to its dialog box state.
This feature allows for a greater degree of customizeability for pro Fit. Developers and pro Fit users can now write useful additions to pro Fit (in the pro Fit definition language itself, or in an external module) with an appropriate and flexible dialog-box interface.
There are already several examples of the new kind of programs and plug-ins that are made possible by the new control-shapes of drawing windows. A simple example is the "Parametric Curve Plotting" dialog box shown below, which allows to plot parametric curves of the kind (x = f(t), y = g(t)) in the current graph (In the example below, f = Sin, g = Gauss).(see Screenshot).
In order to use a drawing window with control shapes as a dialog box, you must "attach" a program to the drawing window (see below). This program is called when somebody clicks or types into a control.
Controls can only be operated when the drawing window is in "dialog box" mode. To bring a drawing window into this mode, either choose "Get Info..." from the File menu and check "Is dialog window", or click into the drawing window while holding down the control key and choose "Dialog Window" from the contextual menu that appears.
Control shapes (and any other shapes) can be accessed by a program using their names. To view and change the name of a drawing-shape, select the shape and choose "Shape Settings..." from the Draw menu. (You can also double-click most shapes for getting into the corresponding dialog box. When a window is in dialog mode, command-double-click a shape to change its settings.)
A detailed introduction to using control shapes is given below.

Plotting
• Bar chart and skyline plots.
• Graphs can now have rotated labels.
• Graph labels can be displayed as date and time.
• Log axes can now have 0, 1, 4 or 8 minor ticks.
• It is possible to set a percentage of the graph range (in a preferences panel) where points and function values are recorded, even if they are outside the graph ranges at the moment of plotting.

Bar charts / Histograms
pro Fit supports two more plotting types: Bar charts and skyline plots (see Screenshot).To use these two types, you choose "Plot Data..." from the "Draw" menu, and then select the desired plot type from the popup menu titled "Plot type". Alternatively, you can change the type of an existing data plot by double-clicking the graph and choosing the "Curves" panel. Several options for bar charts and skyline plots can be set for each graph by double-clicking it and going to the "Bat Charts" panel.

Preferences
pro Fit now looks for/creates a "pro Fit Preferences" folder inside the system's preferences folder. In this folder it looks for a file "pro Fit 5.5 preferences" and creates one if no such file is found. If the "pro Fit Preferences" folder contains a folder named "pro Fit modules", the modules in this folder are linked to pro Fit during start-up.
Various new options have been added to the preferences command:
Preview panel: you can now set more options for the size and color of the various items in the preview window.
Date & Time panel: allows you to set various preferences for displaying dates and time.

top

Numerics Command

Extrema

The Tabulate Extrema Menu command (in the submenu Analyze of the Menu Calc) now produces a data window which also lists the function value at the extremum, not only the x-coordinate of the extremum. Moreover, it differentiates between maxima and mimina by putting them in two different columns.

Binning
pro Fit can now "bin" data, a feature that is useful to create, for example, histograms representing the statistical distribution of some parameter inside a population. "Binning" is the process of putting data into bins, i.e. consecutive intervals. For each data value, the bin or interval it belongs to is determined and the size of the bin is increased by 1. In other words, the number of values in each bin are counted.
Example:
You analyze the height of 1000 people. You put all height values into a data window. Now you want to plot a histogram, each histogram bar giving the number of people that have a height in a given 2 cm interval. For this purpose, you choose "Binning" from the Calc menu, choose your data, define bins of 2 cm width, and click OK. (see Screenshot).
The bins can be distributed linearly, logarithmically, or according to any other scaling type supported by pro Fit. For example, if you want equidistantial bins, use linear scaling, if you want to have one bin over each decade, use logarithmic scaling, etc.

top

Debug Window

Remember the time spent pondering about the code for a pro Fit function you wrote, looking for the place where the code could possibly be wrong and not do what you expect?
These times are over. The new debugging window allows to follow the execution of your code step by step and watch all variables and parameter values while you are doing this.
For debugging a program or function, check the option "Debug" at the top of its window. When you run the program or function, its debug window will show up (see Screenshot).

Now, you can step through your program, view and modify its variables, set breakpoints, etc.
Initially the program stops at the first line of code that is executed. (Note: Some parts of your program may already be called right after compilation, such as the procedure Initialize. In this case, the debugging window will come up right after compilation to let you debug these parts of your code.)

The debug window has four parts:
• At the very top there is a button bar. The significance of each button is explained below.
• At the top left, the "Calling sequence" is shown. This shows through what chain of procedures and functions pro Fit went in order to reach this particular point in your code. Note that you may step through more than one of your programs and/or functions, in the case they call each other.
• At the top right, the variables that are valid at this point are displayed. You can watch and modify their values. Just double-click a value to change it. Clicking the small triangles lets you view the elements of arrays and matrices.
• At the bottom, the source of the program or function is displayed, with an arrow showing the current location.

The top row of buttons lets you control how your code is executed:
• Click Step Into or Step Over for advancing one step in your code. When you click Step Into and the next step is a local function or a procedure, pro Fit steps into this procedure and stops at the first instruction there. If you click Step Over and the next step is a function or procedure, pro Fit will execute it and stop again on the next line. If the next step is not a function or procedure, Step Into and Step Over just advance by one step.
• Click Step Out if you are in the midst of a local function or procedure and you want pro Fit to stop when execution returns from this function or procedure, i.e. you do not want to stop again until the function or procedure is terminated.
• Click Run to continue operation to the next breakpoint or (if there are no more breakpoint) to the end of your code.
• Click Kill to abort execution of your function or program.

You can set "breakpoints" by clicking into the left margin of the source code in the debug window. Red dots mark the breakpoints. To remove a breakpoint, click it again. When you run a program or function and pro Fit encounters such a breakpoint, execution is interrupted and the debug window comes up.

top

System Requirements
Mac

• MacOS 8.5 or higher.
• 2 MB RAM.