User Information

The Center for Gas-Phase Electron Spectroscopy is a multi-user, shared instrumentation facility within the Department of Chemistry and Biochemistry at The University of Arizona. The focus of research in the Center is the investigation of the electronic structure of large, neutral molecules by gas-phase photoelectron spectroscopy.

Photon Energies and Small Molecule Ionizations and "Shadows"

 

Getting started with WinFp

Current version is WinFp 0.015
Build date 08/30/2004
This page last updated on 08/30/2004

Introduction

Workspace Tour

Explanation of The Menu Bar

Basic Data Manipulations

Working with HPGL files

Version Updates and Programming Notes


Introduction

The purpose of this program is to visually manipulate and analyze the data collected from gas-phase photoelectron spectroscopy. Input files for this program are either raw data files from the spectrometer data collection program, or files previously saved from WinFp.  The data is represented analytically by asymmetric Gaussian peaks.  Initial guess peak parameters for Gaussians are entered and then the best fit to the experimental spectrum is obtained iteratively.  The data files created by this program are in a text format that can be edited to be read by spreadsheet or other data analysis programs.  Graphics files of spectral data are created in Hewlett Packard graphics language (HPGL) format.

The program is written in VisualStudio.Net.  The general methodology employed in this program for deconvolution of photoelectron spectroscopic data with asymmetric Gaussians has been described by Copenhaver and Lichtenberger in J. Electron Spectrosc. Relat. Phenom. 1990, 50, 335.


Workspace Tour

The WinFp application window is shown below:

This window contains elements that allow users to access the commands needed to view, edit, fit, and plot data.  The application window contains the following parts:

Menu bar:  Contains commands grouped by category.

Displayed Region Window:  The area in which a spectrum is displayed.  Although more than one spectrum can be open at the same time, commands will be applied to the displayed region only.  The data is a series of points, each with an energy (x-value) and intensity or counts (y-value).  The signal-to-noise of the spectrum is indicated by plotting the data points as vertical lines, with lengths that are proportional to the variance of the intensity.

Region Tabs:  Displays the titles of any open regions.  Selecting a tab will make that region the displayed region.

Cursor and Scale Tool Box:  Displays the energy (x-scale) and counts (y-scale) position of a point in the displayed region that has been selected by the cursor.  Also contains tools to change what portion of the displayed region is shown.


Explanation of The Menu Bar

When the program is started the following menu bar is displayed. 

Selecting one of the commands will cause either a drop-down menu or a tool box to appear.

"File" drop-down menu:

Open Raw Data File(s):  Open data files from the photoelectron data collection program.  Opens a standard Windows Explorer window, one or more files can be selected by browsing to the proper folder.

Open Regions(s):  Open files with .rgn extension previously saved in WinFp.  Opens a standard Windows Explorer window, one or more files can be selected by browsing to the proper folder.

Save Displayed Region As:  Save data and fitting parameters (if present) for the displayed region to a file with a .rgn extension.

Save Selected Regions As:  Save two or more sets of open data and fitting parameters (if present) to files with .rgn extensions.  Opens a dialog box where the regions to be saved can be selected.

Save All Regions As:  Save all open sets of open data and fitting parameters to files with .rgn extensions.

Close Displayed Region:  Closes the displayed region.

Close Selected Regions:  Opens a dialog box where the regions to be closed can be selected.

Close All Regions:  Closes all open regions except for the "scratch" area.

Copy Region to Scratch Area:  Copies data  and fitting parameters (if present) from displayed region to the scratch area, which is then renamed "copy of (name of displayed region)".

Copy Scratch Area to New Region:  Copies data and fitting parameters (if present) from the scratch area to a new region.  Enter name of new region in the dialog box that appears.  This does not mean the data has been saved to a file!

Import:  Import peak parameters from text file in format of previous fitting program (.pek file).

Test Data:  Opens a data file the contains ideal test data created by convolution of three Gaussians and a linear background.

Exit:  Quit the program.

"Edit Data" drop-down menu:

  

Shift Data Energy:  Shifts the energy of all the data points in a region by an entered amount.  Opens a dialog box where a value is entered, with options to "try", "reverse", "keep", or "discard".

Edit Points:  Changes the intensity value of individual data points.  Opens a dialog box, specific data point is selected with the cursor and the new intensity value is entered numerically or selected with the cursor.  Useful for removing sharp ionizations due to electronic noise or presence of ionizations from small molecules or atoms such as water or argon.

Add Spectra:  Adds the data in two or more open regions or files.  Opens a dialog box where the regions to be added are selected.  Most commonly used to add raw data files together.

Subtract Peaks:  Perform a spectral subtraction based on Gaussian fitting.  Most commonly used to perform a subtractions of beta or gamma ionization contributions from a spectrum, or to subtract the contributions from the presence of a known contaminant from a spectrum.  Can also be used to subtract the total fit peaks from the data
to observe the residual of the fit.

Analyzer Sensitivity Correction:  Corrects the experimentally observed relative intensities of data points for the spectrometer analyzer kinetic energy dependence.  This is empirically measured for the specific hemispherical analyzer in our spectrometers.

Subtract Baseline:  Perform a subtraction of a baseline from the data.   Most commonly used to aesthetically correct data for presentation if an inordinately high amount of electron scattering was occurring during data collection.  Also will flatten the residual of the fit display after the fit peaks have been subtracted.

"Baseline" tool box:

Inserts a baseline into the spectral fitting parameters.  The program will guess the best linear baseline for the displayed data region.  The baseline is displayed in the data region in blue.  The baseline can be changed from a simple linear (2 point) baseline to a 3 point or exponential baseline by selecting the radio buttons.  The points that define the selected baseline can be changed by selecting a point on the displayed data with the cursor and then clicking on the "point" buttons or by entering or scrolling through values in the numerical display boxes.  Click on the "x" button in the upper right hand corner of the tool box to close the tool box.

"Peaks" tool box:

Inserts Gaussian peaks into the spectral fitting parameters and performs iterative least-squares optimization. 

Gaussian peaks can be added by setting a cursor position into the displayed region by left-clicking the mouse at the desired location and then clicking the "Add Peak" button.   This adds a peak at the energy of the cursor position.  The initial intensity (counts) of the added peak is set one of two ways. 
1.  Under the "Add Peak" button, if the "Cursor Sets Counts For Total" is selected, the intensity of the peak is set so that the sum of this peak and all other peaks and the baseline passes through the center of the cursor. 
2.  If the "Cursor Sets Counts For Peak" is selected, the intensity of the peak is set so that the total counts for the added peak plus the baseline passes through the center of the cursor, and the contributions of other peaks to the intensity at this point are ignored.

The active peak in the display is colored red.  The parameter values and associated attributes for this peak are listed in the panels above the spectrum display.

When the first peak is added to the spectrum, the low and high halfwidths of this peak are given program default values.  Subsequent peaks that are added to the spectrum are given the same halfwidths as the previously added peak.  For this reason it is a good idea to adjust halfwidths of the first peak to reasonable values before proceeding to the addition of more peaks.  Adjust the low energy halfwidth of the peak first.  Set the cursor to the right of the peak according to the following options and then click the "+" button next to the low halfwidth parameter value in the panel display:
1.  If the "Cursor Sets Counts For Total" is selected, the low halfwidth of the peak is set so that the sum of this peak and all other peaks and the baseline passes through the center of the cursor.  If it is not possible for any real value of the halfwidth for the total counts to pass through the middle of the cursor, the halfwidth is adjusted so that the counts of just the active peak pass through the middle of the cursor.
2.  If the "Cursor Sets Counts For Peak" is selected, the low halfwidth for the peak is set so that the the value of the peak at this point passes through the center of the cursor.

The parameters (position, width high, width low, amplitude) of peaks can be changed by a similar process of setting the cursor position and clicking on the "+" button next to the parameter value in the display panel.  Parameter values may also be manually edited in the display boxes (remember that the "Enter" key must be typed before the typed value takes effect). 

Each peak parameter has associated with it a set of attributes that indicate if the value is to be fixed, if it is to be within a minimum and maximum boundary range, or if it is to be constrained to maintain a value relative to the value of another parameter.  Each peak also has limits on the degree of asymmetry that is allowed, where the asymmetry is defined by the value of the high halfwidth divided by the value of the low halfwidth.  These attributes are necessary because parameter values may have a high degree of correlation between each other (such as for highly overlapping peaks) and the degrees of freedom for the fit should be appropriately reduced.  The attributes of a parameter control the values that are allowed to be set by the user and the values that are allowed in the optimization of the fit.  Occasionally the attributes become in conflict, and in these cases there is a hierarchy for which attribute takes control. The rules are as follows:
1. If a parameter value is fixed, it is not allowed to change from the value input by the user.
2. If the parameter is not fixed but is constrained to vary in concert with another parameter, the constraint is maintained during the optimization process.
3. If a parameter value moves outside the boundary limits, the parameter value is set to the nearest boundary value, and the parameter value is fixed.
4. If the parameter is not fixed and it is not constrained to another value, and the asymmetry of the peak moves outside the asymmetry limits, the value of the high halfwidth of the peak is adjusted so that the asymmetry is at the limiting value.

After an initial fitting guess of peaks for the spectrum is manually set, the peak parameters can be varied by a least squares fitting algorithm to arrive at an optimized fit.  Goodness of fit is reported in terms of χ2 and Rw.  The change in Rw from one optimization step to the next is also displayed to indicate if the goodness of fit is improving with additional optimization steps. 

Click on the "x" button above the "Add Peak" button to close the tool box.

"Collective Peak Actions" Drop-down Menu:

When the "Peaks" tool box is active an additional item "Collective Peak Actions" appears on the menu bar.

Delete All Peaks:  Delete all Gaussian peaks from the displayed region.

Sort Peaks:  Peak # is assigned based on the order in which the Gaussians are added.  Sort peaks so that the Peak # increases from lowest to highest energy.

Scale/Shift/Broaden or Narrow All Peaks:  Change the parameters of all peaks in the displayed region.

Scaling All Peaks
Scale the intensity of all peaks up or down by the same percentage.

What it can be used for:
When peaks are brought in from another region, the amplitudes can easily be scaled (all by the same scale factor) to visually match the intensity of the new data. One example is bringing in peaks from a full region fit for beta subtraction of data collected in a close-up region.  Another example is using the peaks from a fit of one region as a first guess for fitting another region that has different total counts.  The intensity of all the peaks can first be scaled to approximate the new spectrum.

How it works and what the program does:
Three methods to scale:
a. Using Cursor to scale:
    Click set a cursor marker at a point at which you want the peaks sum line to pass through. It is best to pick a point near the position of a peak.
    Click the + button on the scaling panel.
    The peak amplitudes will be scaled so that the sum passes through the cursor marker point.
b. Manual scaling:
    Type a value other than 1.0 in the scaling value box.
Type 'Enter'
    The peak amplitudes are multiplied by the value you typed. The value in the box is set back to 1.0.
c. Step up/down buttons on number box.
    The peak amplitudes are increased/decreased by 0.2%.
Alternative method of scaling all peaks.
See 'Set All Peaks Scaling Constraints'.

Shift All Peaks:
Shifting the position of all of the peaks the same amount.
What it can be used for:
It might help setting up consistent fits of related molecules. This should NOT be used to correct for different energy scales due to different calibrations, such as sometimes occurs between He I and He II data of the same molecule. The 'Shift Data Energy' panel should be used.
How it works and what the program does:
Three methods to shift:
a. Using cursor to shift:
    Click set a cursor marker at a point at which you want a peak to shift.
    Click the + button on the shift panel.
  The program finds the peak closest to the cursor marker position and shifts that peak to that position. All other peaks are shifted by the same amount.
b. Manual scaling:
    Type a value other than 0.0 in the scaling value box.
    Type 'Enter'
    The peak are shifted by the value you typed. The value in the box is set back to 0.0.
c. Step up/down buttons on number box.
    The peak positions are increased/decreased by 0.001 eV.

Change All Peak Widths
Adds a constant value to the low and high halfwidths of every peak.
What it can be used for:
He II data is often collected at poorer resolution than He I data.
When using He I fit peaks to model He II data, the poorer resolution of the He II data may be noticeable. This routine can be used to consistently add width to the He I peaks.
How it works and what the program does:
Type a value other than 0.0 in the 'Change Widths' box. Type 'Enter'. Click the 'Add' or 'Subtract' button.
All peak widths are changed by the amount in the box. Constraint conditions on the widths, if they exist, are then reapplied. Reapplication of width constraints may not be completely appropriate in all circumstances.
If the purpose is to use He I peaks to fit He II data, all width constraints on the He I peaks should first be removed before broadening the peaks. The 'Set He II Constraints' can then be applied after broadening the peaks and before optimizing the fit of the He II data.

Collective Peak Constraining and Fixing:

Set He II Constraints:  Sets constraints on peak parameters such that only the intensities of peaks are allowed to vary in least-squares iterations.  Primarily used to fit He II data beginning with a fit of He I data.

Set All Peak Scaling Constraints:  Sets constraints that force the relative intensity of all Gaussians to remain constant during optimization.  The "Scale All Peaks" option above can be used for a first guess.

Set Constraints for a Group of Peaks:  Opens a dialog box to constrain peak parameters for a group of Gaussians to each other during optimization.

Fix All Peaks Outside the Fit Window:  Fixes all peak parameters for Gaussians outside a particular energy region.

Remove All Constraints:  Removes any optimization constraints from peak parameters in the displayed region.

Remove All Fixes:  Removes any optimization fixes from peak parameters in the displayed region.

"HPG Plot" Tool Box:

Used to create graphics files of plots in HPGL format.  HPGL stands for "Hewlett-Packard Graphics Language".  To add a region to a plot have it as the displayed region and click the "Add Region" button.  Maximum number of regions that can be included in a plot is 25.  Select what components to include in the plot using the check boxes.  "Preview" will display the plot as currently set up in a separate window.  "Write File" opens a standard Windows Explorer window, browse to the folder where a graphics file is to be written and enter a name.  Click on the "x" button in the upper right hand corner of the tool box to close the tool box.

There are numerous options for controlling the scaling and aspect ratio of the plot.
Energy Range:  The first region added to the display with 'Add Region' will define the energy range.  The energy range can be customized for the region using the 'Energy Range' option in the 'View' drop-down menu.  The energy range can be set beyond the actual data range.
Counts Range:  The counts range for the region in the plot will be retained as displayed in the region display (which also may be set precisely with the "Counts Range' panel in addition to the cursor control options).
Stack Plots:  Stack plots are created by subsequently adding regions to the plot.  The "stack" builds from the bottom to the top as regions are added.  The starting height and ending height for each region window in the stack is controlled by the 'Offset' and the 'Scale' for each region added.  The default is to create equally spaced and equal height windows for each region in the stack - thus the default offset is 100% and the default scale height is 100%.
Aspect ratio: The aspect ratio may be set by the 'Set H:W to' ratio.  Alternatively, the 'Preview' graph window can be resized by grabbing a corner of the window and dragging it to give the desired shape, and then reclicking 'Preview'.  The 'Write File' will retain the aspect ratio for the HPGL file and set the width appropriate for a column of a publication.

After the 'Preview' display is satisfactory, the 'Write File' button saves the HPGL format file for creating figures and hardcopy print out.  See the notes about working with HPGL format files.

"View" Drop-Down Menu:

Provides options for the display and for showing selected information about the displayed region.

Region Log File:  Displays a listing of information on what manipulations have been performed to the data in a separate window.  This file is also saved with the data in the .rgn files.

Current Peak Parameters:  Displays the positions, widths, and relative areas of the current peaks in a separate window.

Select Normalization Peak:  Select which peak will have its relative area taken as 100 in Current Peak Parameters.

Energy Range:  Allows precise control of the energy ranges for the displayed and HPG-plotted data.  The energy range may be set individually for each displayed region.  In addition, an energy range may be defined as global.  A region display may adopt a custom energy range or the global energy range by displaying the region and choosing the appropriate option on the 'Energy Range' panel.

Counts Range:  Functions the same as the 'Energy Range' but applies to the counts scale for the display and plot rather than the energy scale.

Select Peaks Panels:  Sometimes too much information and too many panels are on the screen when adding peaks and fitting the data.  Selecting this option brings up a panel that allows you to take Peaks panels off the display, put panels back on the display, or reorder the panels on the display according to the order in which they are added to the view.

"Help" Drop-Down Menu:

Help:  Opens a web browser window to a web page where information about WinFp can be found.

About Help:  Displays the information on the web browser and web address that will be used to display Help.

About WinFp:  Gives current version and date information.


Basic Data Manipulations

Adding Data:

Data collected is usually a series of files for a given energy region that will need to be "added" to each other to give a final spectrum.  Adding files to each other adds the counts (y-values) from each file to to indicate increasing signal-to-noise.  After a series of data files has been opened a first order visual comparison can be made be clicking through the region tabs to bring the different files into the displayed region.  Begin to decide if any individual data files should not be included in the added spectrum based on how well they agree with the other files.  For example, the first several files saved during a data collection may not show enough signal above background to be useful and should be discarded.

To add the data files together select "Add Spectra" from the "Edit Data" drop-down menu.  In the displayed dialog box:

Select one file from the first box, and select any others to be added to it from the second box.  Click the ADD button, and the new added data will be displayed in the "scratch" region:

The data points are displayed in black (note that as the signal-to-noise of the data increases by adding several files together, the variance of the data points decreases), and a line is drawn through the data points in green.  Click through the regions tabs, and the green line will continue to be displayed so that the added data and individual data files can be farther compared as an additional check that only appropriate data was added together.  Click on the KEEP button and enter a name for the new spectrum in the dialog box that appears.

Analyzer Sensitivity Correction:

The analyzer sensitivity correction must be performed to all data to get the correct relative intensity of ionizations.  Select "Analyzer Sensitivity Correction" from the "Edit Data" drop-down menu.  A dialog box will be shown:

and a blue line will be drawn in the displayed region to show how the instrument sensitivity is dependent upon the corresponding kinetic energy of photoelectron measured (experimentally measured sensitivity is artificially large for higher kinetic energy, or lower ionization energy electrons).  Make sure that the photon energy used to collect the data is displayed in the dialog box, or select the source with the corresponding radio button.  Click "Execute" to sensitivity correct the data.


Working with HPGL files

HPGL files are simple text based, vector format graphics files that should be readable by most graphics programs.  HPGL stands for "Hewlett-Packard Graphics Language".

The files created are "bare bones" graphics that will most likely need to be further edited with a graphics program to create publication quality figures.  We commonly use either CorelDraw or Corel Presentations (part of the Corel Wordperfect Suite) for preparing figures for publication.  Editing the vector format files is fairly straightforward because the figure is comprised of a series of individual lines, curves, or text that can be individually selected and changed.

Microsoft Office:  See Microsoft Knowledge Base Article 196506 to download the 32 bit HPGL filter for Microsoft Office.  After this patch is installed the graphics files can be edited with Microsoft Powerpoint or inserted as a picture into Microsoft Word. 

[Note:  The default .hpg extension used by WinFp is not automatically recognized by the Microsoft filter.  To add it, edit the HPGL.reg file that will self extract from the downloaded hpgl32.exe and add hpg to the "Extensions".]