Contents

 FGraph for Windows 2.0
Help Contents

Most operations and functions should be fairly obvious.

Absolutely no guarantees or claims are made about this program.  Use at your own risk!

Introduction / Overview

Plot Formatting:
 Axes
 Plot Options
 Page Setup

Input/Output:
 Importing Data
 Plot Files
 Printing
 Exporting Plot Graphic

Misc:
 Zoom Feature
 Mouse Controls
 Floating Text
 Data Cursors


Overview

FGraph for Widows  	by Marc Felisky
Version 2.0    	May, 1993

Introduction:

FGraph for Windows is a simple plotting program for MicroSoft's Windows 3.X.  It is a quick and flexible tool for plotting moderately sized scientific X-Y data sets, the kinds of sets that are awkward in most spreadsheets or other business oriented plotting packages.  It DOES NOT do bar charts, area charts, any kind of 3-D thingies or any other presentation oriented functions.  FGraph does only traditional X-Y scatter plots with single X and single Y axes.  However, it does them quickly and efficiently, with a minimum of hassle and incorporates a fairly simple interface.  The two biggest shortcomings for scientific type plots are the single X and Y axes per plot, and lack of error bars.  It does provide a good amount of control over plot appearance and output for those X-Y plots.  Data line styles, symbols, grids, tickmarks, and page layout are fully user controlled.  FGraph is especially useful for creating plot graphics that can be pasted into other applications but note that some programs can not deal with the rotated TrueType text of the Y-axis label, either completely ignoring text rotation, or interpreting the 90 degree rotation clockwise, instead of counterclockwise.

NOTE:  Currently it supports ONLY TrueType fonts.  You need to have at least Microsoft's 'Arial' font that came with Windows 3.1 installed for this program to work correctly.

This is my first experience programming windows, and no guarantees or claims are made about performance, features, buginess, or anything else!  Use at your own risk.

Features:

* Reads multiple (<=5) column ascii data files.
* Graphs up to 10 datasets, each up to 8150 points.
* Data files can be imported either by standard "File/Open" menu selection, dragged and dropped from File Manager, or by command line arguments, ie using the 'Associate' feature in File Manager.
* Graphical output includes printing, clipping to clipboard, and saving as a ".WMF" windows placeable metafile.
* Can save all plot settings and data in a plot/parameter file.
* Simple dataset mathematical manipulations.
* Mouse oriented user interface, plus many keyboard shortcuts.
* Legends.
* Floating text blocks.
* Line and symbol style of each data set fully controllable.
* Log Y-axis.
* Any TrueType font may be used for any text, including title, axis labels, tickmark numbers, and floating text blocks.
* Two viewing modes:
Normal View, used for normal viewing.
Page View, used for page layout.
* Easy page setup by using a dialog box or click and dragging margin handles in Page Vview.
* Click and drag zooming feature, and with zooms saved in stack for unzooming.
* Cursors on data.

 See...
Contents


Axes

The plot contains two axes, the X, and Y.  The user can access the axis setup dialog box by either selecting the menu item under the  Controls  menu, by pointing near the particular axis and clicking the right mouse button, or by pressing the 'X' or 'Y' keys on the keyboard.

The user has control over format of the axis:
Axis Limits

Ticksmarks

Axis Labels

Linear/Log


Importing Data

Data Files

Valid data files text files containing from 1 to 5 columns of data delimited by either whitespace (space or tab) or commas.  Up to 8150 data points are allowed and 10 datasets can be loaded and displayed at one time.  If the first lines in the data file are header text, the program usually can ignor  them and extract later data.  For one column files, the X's are simply the integer index.  For two column files, the first column is taken as X, and the second as Y.  If more the 2 are found, the program prompts the user to select which column corresponds to both the X and Y data set values.

There are 3 ways of importing data files into FGraph:
1) The standard  File Open  menu command, which ALLOWS MULTIPLE selections in the File Open Dialog box for convenience.
2) Drag and Drop is implemented.  The user may  simply drag a file (or set of files) from File Manager and drop them into the FGraph window or icon, which will immediately attempt to load and plot them.
3) Lastly, FGraph parses the command line which enables the File Manager "Association" function to operate.  Simply use the Associate command in File Manager's File menu to attach a suffix (".dat" for example) to (PATH)FGRAPH.EXE, and from then on, simply double clicking ".dat" files in File Manager will launch FGraph and immediately plot the data.  The command line might possibly be used by batch programs/languages as well.

See also..
Data Set Box

Saving Data Sets


Linear/Log Plots

Log Plots

Log plots are supported if the user selects the "Log Axis" checkbox in the Axes dialog.

Note:  Currently only the y-axis supports log scaling!!  The X-axis log flag is ignored.  (However, you can transform the X values using log10 function in Data/Math...)

See also..
Axes


Registering

Registering FGraph

FGraph's author is a poor starving graduate student, with a wife in medical school (serious debt!).  If you find FGraph useful, a nominal registering fee of $15 dollars would be appreciated.

Registering entitles you to responses concerning bugs and suggestions for new features.  New versions might be available depending upon the volume of responses.

Send $15 check or money order and any suggestions for improvements to:

Marc Felisky
711 Old Farm Road
Valhalla, New York  10595

e-mail(until mid-Sept 1993):  felisky@eeap.ogi.edu


Axis Text

The axes have text labels which are automatically centered on either axis and accessed throught the standard axis control dialog (right mousebutton clickingnear the axis itself) or the Plot Text dialog (right mousebutton clicking either axis text or the title text).  The Y-Axis is rotated 90 degrees, which is why the program only works withTrueType fonts.

See also..
Axes
Fonts


Ticks

Tickmarks

There are two types of tickmarks: major and minor.

The tick's spacing, labeling and label font is controlled through the  Axes dialog boxes.  Here the major tick spacing is specified either by manually entering the value, or using the automatic spacing which gives five major ticks over the limits of the plot.  The minor ticks are given as an integer number fractional size of the major tick spacing.  The default (which can be which can be changed in the  Preferences) is 5, meaning that the minor ticks are spaced intervals of (major ticks)/5.  The major ticks may be labeled with a user specified font (TrueType Only).

NOTE:  The numerical format of the ticks is not currently under user control-- they are displayed using the fewest possible number of characters while keeping the same precision for all tick marks labels.

Other aspects of tickmarks are controlled through the Plot Setup and  Preferences dialog box.  Here, the size of both the major and minor ticks may be manually set.  The option of whether to have ticks on either just the two main axes, or on all four all sides of the graph may be selected.  You may also replace the major ticks with grid lines if the Grid Line box is checked in the Axes dialog.

HINTs:
- To make a graph with no ticks, set the tick sizes to 0.0.
- To make the ticks on the outside of the plot, make both  tick sizes negative.
- To make a graph with no minor ticks, set the Minor Tick value equal to 1 in the axis control.

See also..
Axes
Plot Setup


Axis Limits

Limits of the X and Y axis are controlled by using the respective axis dialog boxs.

The start must be less than the end.  This is enforced when you change  the focus away from the edit field (ie click anywhere else in the dialog, including the OK button).  The automatic tick spacing is also enforced when the focus is changed away from either the START or END edit fields.  If you edit either value, the respective AUTO checkbox shuts off, reflecting a manually entered value.  The  Zoom Feature also turns off the Start and End automatic flags, but the automatic tick spacing remains in effect if selected.

The  Auto button searches through all current data sets to find either the maxima or the minima to set the axis limits.  There is a preference for rounding the minima to 0.0 if it is already close.

See also..
 Axes
 Tickmarks


Normal View

Normal View is the standard mode for viewing the plot.  The plot is scaled to the full size of the main FGraph screen window.  All symbols and fonts are scaled to the screen pixels/inch dimensions.

Note: Floating text blocks that are outside the standard view window will not show up in Normal View.  They will always be displayed in  Page View .

See also..
 Page View


Grid Lines

Grid

Major tickmarks can be replaced by a grid lines.

The Grid Lines checkbox is in the Axis control.  The line thickness and dash length (<=0 for solid line) is controlled eitherin the  Plot Options  box or  globally in the  Preferences  dialog.

See also..
 Axis
 Plot Options
 Preferences


Page View

Page View is the mode for viewing what a printed (or exported) plot would look like.  A page is drawn using the current page setup and all items (fonts, symbols, etc) are scaled as they would appear on the printed page.

All standard mouse controls are still available for changing plot settings except the  Zooming  and  Data Cursors functions,

 See also..
Normal View
Page Setup
Printing
Exporting Graphic


Printing

The plot as viewed in  Page View  can be printed to the current printer.  No Printing Abort option is implemented, so be be sure there are no problems before printing.

NOTE: Some printer drivers do not handle the rotated text very well.  The HP LaserJet III printer driver that came with MicroSoft Windows version 3.1 (dated 3-10-92) has problems correctly spacing the Y-axis labels.  MicroSoft's newer PCL5/UNIDRV.DLL Universal printer driver combination (dated 10-22-92 or later) is required for correct output when using the HP LaserJet III.  Other drivers might have problems as well, although most that use the 'UNIDRV' should work correctly.  Printing has been tested on several standard dot matrix printers.  If there problems remain, export plot graphic to a more reliable application for printing.

See also..
Exporting Graphic
Page Setup
Page View


Export Graphic

Exporting Plot Graphic

There are two ways to export the plot graphic.  Both methods will produce a graphical object that corresponds to the Page View mode.

 Clipping and Pasting

The plot can be copied to the clipboard by using the "File/Copy to Clipboard" menu command and then pasted into any application that accepts graphical objects.  Objects such as fonts, symbol size and line thicknesses are maintained at the specified size, although the destination application sometimes scales the entire graphic for its own purposes.

 Saving as Placeable Metafile
The current plot graphic can be saved in a more permanent fashion by selecting File/Save as Metafile... menu command.  The graphic is then saved to disk as a Placeable Metafile with a default "WMF" suffix.  Any application can then load this file as standard graphical object.

NOTE: Some applications have problems dealing with the rotated text of the Y-Axis.  While pasting or importing plot graphic into current word processors should work fine, simple built-in graphic editing programs (MS Draw, for example) sometimes do not support rotated text.  Also, some drawing programs (CorelDraw, for example) specify text rotation in the opposite sense during translation and so the Y-Axis label text appears flipped 180 degrees.

See also..
Page View
Page Setup
Printing


Page Setup

The basic page layout settings are controlled through the Page Setup Dialog box.

The four margins correspond to locations of the actual plotboundaries, a 'viewport.'  For example, the left margin value corresponds to horizontal location of the start of X axis.   The tick labels and axis labels are then located outside this 'viewport.' All values are in inches.

The user may select the page orientation, either Landscape or Portrait.

These combination of these settings determine how the plot will be placed on the page, and are previewed by using Page View.  Note, these settings have NO effect upon Normal View.

In Page View, you may use the small black boxes near the edges of the displayed page as 'handles' to easily click and drag the margins.

See also..
Normal View
Page View


Plot Options

This dialog control contains the basic less frequently used options for controlling plot appearance.
The "plot pen" is the line used to draw the axes, tickmarks and the box around the plot if specified.  All line thicknesses in FGraph are are specified in inches.  Tickmark options such as size and whether they are drawn on all four sides.  The dash style and thickness of the grid lines are also specified here.  A dashlength of 0.0 means a solid line.  The option to draw a line at the axes 0 values can be selected.

HINT: If you need a multiple line title, use Floating Text and place it in Page View.

See also..
Axes
Normal View
Page View
Tickmarks
Grid


Data Sets List

The box displays information about the currently and displayed data sets.

The table of information is:
- Data set number
- File name
- (number of columns in the file)
- Number of points in the data set.
- Minimum and maximum X values for each set.
- (column number of the X values)
- Minimum and maximum Y values for each set.
- (column number of the Y values)
- A sample of the line style.

After selecting a dataset, there are several buttons that allow for certainactions:
The  Reread  button reads the selected dataset again from the current data file again.  This is useful for quick updating of the output of a simulation progam without having to use the File Open dialog box, or for changing the columns that are plotted by rereading a file and selecting different columns for the X and Y data ( see Importing Data ).
The other buttons are self explanatory.

See also..
Data Math
Importing Data
Line Style


Line Style

Line and Symbol Styles

The line and symbol styles of each data set is controlled through the line style dialog box accessed by pointing at the dataset and clicking the Right Mouse Button, through the  LineStyle  button in the Data Set List  or by double clicking the data set in the Data Set List.

Here, all units are in inches.  The symbol style and line color are  selected by pointing and clicking the left mouse button.

An example of the current line style is shown in the lower left side of the dialog box which is immediately updated after each change in the settings.

See also..
Data Sets List


Floating Text

Multiple line text blocks are created using the  Controls/Add Floating Text  menu selection or by hitting the 'A' key.  Up to ten blocks can exist at one time.  The text is located according to a X and Y value associated with the actual values of the data plotted.  NOTE: the text is not anchored to fixed locations on the page or fixed position relative to the axes (like the Legend).  It floats with the data.

The floating text dialog contains a text entry field, the X and Y values (default being the middle of the plot) specifying the upper left corner of the text in coordinates of the X and Y axes, a <FONT> button to change the font for the text block, and a <DELETE> button which will delete the particular text block.

To edit an existing text block, simply point the mouse at the text, and click the RIGHT mouse button.  To move the text, point and click the LEFT mouse button and then drag to the desired location.

If the floating text block is moved completely outside the plot when in Page View, it will not be visible in Normal View but it still exists.

See also..
Legend


Zooming

The user "Zoom"-in on a portion of the plot using the mouse to set the X and Y axis limits.

After selecting the Controls/Zoom  menu item, the mouse pointer becomes a cross hair.  Now click and drag a box around the sub area of interest in the plot. When the mouse button is released, the plot is redrawn with the new limits.

Previous limits are pushed onto a stack, and the Controls/UnZoom  menu item resets axis limits to the previous values.  Up to ten values are stored, and repeating the Controls/UnZoom  selection pops back up through the stack of stored settings.  The UnZoom menu item is unavailable if there are no zooms.

Zoom presently does not work on Log-Linear Plots, and resetting the plot also resets the zoom stack.

See also..
Axes
Axes Limits


Mouse

Using the Mouse

Most frequently used functions and options are available by pointing and clicking either the left or right mouse button.  In general, the left mouse button is for actions, and the right mouse button pops up dialog boxes depending upon where in the plot the mouse is pointed.  The mouse works both in Normal View and Page View modes.

Clicking the Left Mouse Button inside the plot brings up the Data Set List.

Clicking the Right Mouse Button brings up the nearest dataset's Linestyle control.

Pointing at either the X, or Y axis and clicking the Right Mouse Button brings up the respective axis' dialog box.

Pointing at either axis' text label or the title area calls up the Plot Text dialog, for control of the axis labels, title text and the fonts of each.

Pointing at Floating Text or the Legend on the plot has two options: Holding down the left mouse button allows you to drag the text block to a new  location.  Clicking the right mouse button brings up the respective control dialog, where you can manually enter position, edit the text, change the font or delete the object.

In Page View, the page layout can be changed by clicking the left mouse button on the 'margin' handles and dragging.

See also..
Floating Text
Legend
Page View
 Zoom Feature


Data Math

Data Set Math

Simple mathematical operations can be performed on loaded data sets.  The Data Math dialog box is accessed through Data/Math... menu selection or hitting the 'M' key.  Sets can be duplicated, (where everything including linestyle, name, etc. are copied into a new data set--use this to create 'work' or 'scratch' sets), saved to ASCII file, deleted, and more.

Pressing the "Do" immediately carries out the element by element vector actions described in the "Result", "Function", "Operand 1", "Action" and "Operand 2" controls.  (Note that the "Do" button is not the default button, therefore you must specifically click the "Do" button or hit Alt-D to carry out the action.)  In the "Result", "Operand 1" and "Operand 2" boxes, data set columns are represented as two character strings, ie "X2" means the X values of the number 2 dataset, and so on.  "Result" can only have a data set column string, whereas either "Operand" box may instead have a manually entered number.  The data set strings may also be manually entered.

Several mathematical functions can be used to transform the data of a set, specifically sqrt(), log10() and 10^().  While you may select a 'Function' and an 'Action', FGraph can only do one operation at a time.  It will ignore the 'Action' if a 'Function' is selected,  and "Operand 2" is always ignored when doing a 'Function' operation.

Point and clicking data sets in the main listbox automatically fills the Result and Operand boxes with the column selection as specified by the "Default" selection.

Example 1) Subtract a baseline set from another data set.
- Make sure the "Default" selection is "Y"
- click on the main data set
- click on the baseline data set
- select "-" (minus) from the <Action> list
- click the <DO> push button.

Example 2) Normalizing a dataset.
- Make sure the "Default" selection is "Y"
- click on  the data set
- enter the maximum value shown for that dataset
in "Operand 2"
- select "/" (divide) in <Action> list
- click on the <DO> push button.

Example 3) There are no log X plots, but you can transform the X axis values by a log10 function.
- Make sure the "Default" selection is "X"
- click on  the data set
- Select "log10" from the function box.
- click on the <DO> push button./line
Note: The number of points in each dataset must be the same.

See also..
Data Set List
Importing Data
Save Data Sets


Saving Data Sets

Individual data sets may be saved to an ascii file in X, Y tab separated format from the Data Math  dialog box.  Note that with files that orginally contained more than 2 columns, only the present X and Y columns will be saved.

Data may also be saved as part of the binary plot files when using the File/Save Plot  command when the 'Save Data' option is selected.  The user has no direct access to this data other than through FGraph.

See also..
Data Math
Importing Data


Plot Files

FGraph can save the state of the current plot into a plot file with the default suffix ".FGR".  These plot files contain all axis' settings, and all plot text.  They may optionally also contain actual data sets, and so can be used as simple parameter files with standard axes labels, etc, or as complete plots saved for later modification.

To save a plot, select the File/Save Plot menu selection.  If you want to create a self-contained plot file that includes all current data sets, check the 'Save Data' Box.  Otherwise, only the parameters of the current plot will be saved.

To use an existing plot file, select the File/Open Plot menu selection.  The parameter settings in this plot file will overwrite all settings currently being used. (Existing Floating Text will be discarded.)  If there are data sets in the plot file, they will be loaded if there are no data sets present.  If there are existing data sets, the user will be prompted for three options:  add the plot file's data sets to the existing data sets, discard the existing sets, or ignore the plot file's data sets and extract only the plot file's parameters and settings(so ALL plot files can be used as a parameter files).

These plot files can be loaded in the same manner as data files, ie they can be on a command line or 'dragged and dropped' from File Manager.

See also..
Importing Data


Preferences

Some default settings, such as plot line thicknesses, tick sizes, and all fonts can be changed through using the Preferences dialog box acessed through the File menu.  These settings are stored in the "FGRAPH.INI" file in your WINDOWS home directory which is read at FGraph startup, and when the Options/Reset All menu command is selected.

Note that when you change a preference, it does not immediately affect the current plot.  Select Options/Reset All command to apply the new preferences to the current plot.  Note that Reset All  destroys all plot text items and clears the Zoom Stack.

See also..


Legend

FGraph can provide a legend, which consists a line and symbol sample followed by a single line of text for each data set.  In the  Preferences  box, the user can specify whether the legend is automatic, or manually added.

To create a Legend, select the Options/Legend menu item (or hit 'L').  The Legend dialog box allows you to edit text labels, change the font, put a frame/box around the legend, change the length of the sample line, and control the location of the legend.  You may also delete an existing legend, using 'Delete' pushbutton.  To edit the legend text: point the mouse to the item in the listbox; the text will then appear in the edit box; edit text as desired but DO NOT use <ENTER> to finish editing (unless you are completely finished with the legend).  Hit <TAB>, <down arrow> (or click with mouse) to edit the next data set's text.

The "Auto Placement" puts the legend in the upper right corner of the plot.  The X and Y position are fractions relative to the plot, not real coordinates, ie (0.5, 0.5) means the upper left corner of the legend will be placed in the center of the plot, regardless of the X and Y axis ranges.

To move the legend manually, simply point to legend, and drag to a new location using the left mouse button. To quickly access the Legend Dialog box, to remove a legend for example, simply click the right mouse button on the legend or hit the 'L' key.

The legend uses the same default font that's used for Floating Text, as set in the  Preferences  dialog.

See also..
Floating Text
Mouse


Keyboard

Keyboard Shortcuts

The more common dialog boxes can be quickly accessed by single keystrokes, such as 'X' for the x axis box.  These are listed in the main menus.  Either upper or lower case can be used.

See also..
Mouse


Cursors

Data Cursors

Two cursors can be placed on any data set.  The data point values of both points and the difference between the two are displayed in the upper right corner of the FGraph window.  Cursors only appear in Normal View.

The cursor controls are:
-Drag cursors by pointing and holding down left mouse button.
-left and right arrow
-<Ctrl> left and right arrow for 'fast' movement
-Up or down arrow toggles cursor focus for keyboard control.
-<SpaceBar> cycles through current data sets

Currently, the data cursors can only be present on a single dataset.

See also..
Mouse