Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
Filename | Input | string | Mandatory | The name of the SPE file to load. Allowed extensions: [‘.spe’] |
OutputWorkspace | Output | MatrixWorkspace | Mandatory | The name to use for the output workspace |
Loads the file given into a Workspace2D with the given name. The file should be in the SPE format, which is described here. The workspace will have X units of Energy transfer. The other axis will be binned and have units of either Momentum transfer / Q or degrees, depending on the label in the input file. The workspace will be flagged as a distribution.
The expected file format is detailed on the SaveSPE v1 page.
Example - Load an SPE file:
#run the loader by pointing it at the appropriate file.
#If it's in your managed user directories there's no need for an absolute path
ws1 = LoadSPE("Example.spe")
print "Number of Spectra:", ws1.getNumberHistograms()
print "Number of Bins:", ws1.blocksize()
Output:
Number of Spectra: 32
Number of Bins: 195
Categories: Algorithms | DataHandling | SPE | Inelastic