ILabPascal - Sample Scripts

The following table gives an overview on the installed default scripts. The third column lists the functions which are used by the particular script.

Script Description Used Library Functions
addnoise Adds noise to the data. You can set the contribution of homo- and heteroscedastic noise separately. ConfigDlgComponent, CreateDialog, SizeL, MessageDlg, PerformBulkTransform, ShowDialog
dupdataset Duplicates a spectral group of the current dataset. ConfigDlgComponent, CreateDialog, DuplicateGroupAndAppend, LayerTypeCaption, GroupIsDefined, MessageDlg, ObtainSpecRange, ShowDialog
bodydata A sample dialog which shows how to collect body data. ConfigDlgComponent, CreateDialog, ShowDialog
layersum Lets you select several layers, then calculates the sum of the selected layers and displays it as a special image in the 2D Imager. AddImgToRepository, IntList, SelectLayer, SetLength, WeightedSumOfLayers
matdiff Calculates the finite differences of layers and replaces the original dataset by the calculated differences. The user can specify the range of layers to be processed. Please note that the last layer is left unchanged. The script is assigned to a button in the toolbar area. CombineLayers, ConfigDlgComponent, CreateDialog, FuncMon, ResizeMatrix, ShowDialog, ShowStatus, SizeX, SizeY, SizeL
samplescript Lets you load a dataset from the disk, zooms into the image and then calculates the second derivative of the spectra (this script is just a sample script to show a few commands. DeriveSpectrum, DisplayImage, GetILabDir, GetSpectrum, IndexToWorld, LoadILabFile, MessageDlg, SelectFile, SetSpectrum, ShowStatus, SizeX, SizeY, SizeL
stitchgui Lets you select a directory containing ENVI encoded files which have to be stitched together. The script assumes that the positions of the individual tiles are encoded in their filenames. DisplaySpectrum, GetLayerProps, MessageDlg, SetLayerProps, ShowStatus, StitchCubes, StitchDialog
template The template script is the script which is loaded by default when you create a new script (command File > New of the script editor). The template script initialises a few often needed variables by calling a subroutine. CubeSize, ResizeMatrix, ResizeVector