Swansea University (UK) and Karlsruhe Institute of Technology (GER)

- an OpenSource software package

Automated Quantitative Spectroscopic Analysis Combining Background Subtraction, Cosmic-Ray Removal and Peak Fitting programmed in LabVIEW


An integrated concept for post-acquisition spectrum analysis was developed for on-line and off-line applications, which preserves absolute spectral quantification; after the initialising parameter set-up only minimal user intervention is required. This spectral evaluation suite is composed of a sequence of the tasks addressing specifically: cosmic-ray removal, background subtraction and peak analysis / fitting, together with the treatment of 2D CCD array data. Individual steps can also be used on their own or excluded from the chain if so desired. For the background treatment the canonical rolling-circle filter (RCF) algorithm was adopted, but it was coupled with a Savitzky-Golay filtering step on the locus-array generated from a single RCF pass. This novel only-two-parameter procedure vastly improves on the RCF’s deficiency to overestimate the baseline level in spectra with broad peak features. The peak analysis routine developed here is an only-two-parameter (amplitude and position) fitting algorithm, which relies on numerical line shape profiles rather than analytical functions. The overall analysis chain was programmed in National Instrument’s LabVIEW; this allows for easy incorporation of this spectrum analysis suite into any LabVIEW-managed instrument-control and/or data-acquisition environment.

Applications & subVIs

The programme package has been programmed in National Instrument's LabVIEW. A single routines are provided as subVIs for custom use in own applications. In addition, user friendly application suites are included in the packages.


Astigmatism-array-creator.vi, Spectrum-Processing-Suite.vi


Characterisation-Suite-(Astigmatism)-VI.vi, Copyright-VI.vi, Correction-(Astigmatism)-2D-VI.vi, Dialog-Astigm-VI.vi, Dialog-DeadPixel-VI.vi, Dialog-Median-VI.vi, Dialog-ROI-VI.vi, Dialog-SCARF-VI.vi, Dialog-ShapeFit-VI.vi, Dialog-TCRR-VI.vi, Gaussian-w-offset-VI.vi, Load-Fit-Settings-VI.vi, Load-Input-Files-VI.vi, PeakCalc-VI.vi, Preview-window-VI.vi, Remove-Dead-Pixels-VI.vi, Save-Fit-Settings-VI.vi, SCARF-VI.vi, ShapeFit-VI.vi, SimSpec_(ShapeFit)-VI.vi, Sum-Spectrum-VI.vi, TCRR-VI.vi


This package contains extensive documentation: a copy of the paper submitted to Applied Spectroscopy, the corresponding "Supplemental Material" to paper with detailed description of all methods, extensive help files, samples files and a tutorial.

Copyright & License

All applications and subVI contained in the "Spectools" are free software and licensed under terms of the GNU General Public License.

How to cite?

The applications and subVI in this software package are the supplement of a publication in Applied Spectroscopy. If you have used this software for scientific or other purposes the please cite the following paper: T. M. James, M. Schlösser, R. J. Lewis, S. Fischer, B. Bornschein, and H. H. Telle, "Automated Quantitative Spectroscopic Analysis Combining Background Subtraction, Cosmic-Ray Removal and Peak Fitting", Applied Spectroscopy, 2012 (Volume and Issue will be supplied soon!)

Software archive

The latest version of the Spectool package can be obtained from the sourceforge http://sourceforge.net/projects/spectools/

LabVIEW version support

Current package version

SpecTools Version 1.1.0


In order to execute the binaries a run-time engine for LabVIEW 2009 needs to be installed. The run-time engines can be downloaded from National Instruments. Run-time engines are available for Windows, Linux and MacOS.


Supported LabVIEW versions: LV9.0 (2009)

Change log

4. July 2012

- Help files added
- Minor changes to tutorial

28. June 2012

- Minor changes to Spectrum Processing Suite (Astigmastim correction with ROI in batch mode fixed and some visual details)
- Tutorial and further sample files added

Missing: help files

26. June 2012

- Load Spectrum VI changed(to enable single spectrum operation when TCRR is deactivated)
- Astigmatism creator spectrum save-format unified.
- Astigmatism correction with ROI enabled.
- Tuning dialog updated.
- Minor changes to Spectrum Processing Suite
- Documentation added

Missing: Tutorial; help files

19. June 2012

- Single/batch processing bug in Spectrum processing suite fixed.
- Copyright information added to all VIs.
- Sample files added

Missing: Tutorial; copy of paper and supplementary materials; help files;

18. June 2012

Missing: Tutorial and sample files; copy of paper and supplementary materials; help files;