SaveLauenorm v1

../_images/SaveLauenorm-v1_dlg.png

SaveLauenorm dialog.

Summary

Save a PeaksWorkspace to a ASCII file for each detector.

Properties

Name Direction Type Default Description
InputWorkspace Input PeaksWorkspace Mandatory An input PeaksWorkspace.
Filename Input string Mandatory Select the directory and base name for the output files.
ScalePeaks Input number 1 Multiply FSQ and sig(FSQ) by scaleFactor
MinDSpacing Input number 0 Minimum d-spacing (Angstroms)
MinWavelength Input number 0 Minimum wavelength (Angstroms)
MaxWavelength Input number Optional Maximum wavelength (Angstroms)
SortFilesBy Input string Bank Sort into files by bank(default), run number or both. Allowed values: [‘Bank’, ‘RunNumber’, ‘Both Bank and RunNumber’]
MinIsigI Input number Optional The minimum I/sig(I) ratio
WidthBorder Input number Optional Width of border of detectors
MinIntensity Input number Optional The minimum Intensity

Description

Provide input files for the program LAUENORM which is used to perform a wavelength normalisation for Laue data using symmetry equivalent reflections measured at different wavelengths.

Input_Files

Unit 21 LAUE001 Input Laue data file. This is normally a card image file with one record per reflection (unmerged, unsorted data) containing the items: h k l lambda theta intensity and sig(intensity) in format (3I5,2F10.5,2I10).

Unit 22 LAUE002

Unit 23 LAUE003

Continuing

From: http://www.ccp4.ac.uk/newsletters/newsletter36/10_laue.html

Usage

Example - a simple example of running SaveLauenorm.

import os

prefix = os.path.expanduser("~/MyPeaks")
#load a peaks workspace from file
peaks = LoadIsawPeaks(Filename=r'Peaks5637.integrate')
SaveLauenorm(InputWorkspace=peaks, Filename=prefix)

firstfile = prefix + "001"
print "File was saved:", os.path.isfile(firstfile)

Output:

File was saved: True

Example - an example of running SaveLauenorm with sorting and filtering options.

import os

#load a peaks workspace from file
peaks = LoadIsawPeaks(Filename=r'Peaks5637.integrate')
print "Number of peaks in table %d" % peaks.rowCount()

prefix = os.path.expanduser("~/MyPeaks")
SaveLauenorm(InputWorkspace=peaks, Filename=prefix, MinWavelength=0.5, MaxWavelength=2,MinDSpacing=0.2, SortFilesBy='Bank')

finalfile = prefix + "009"
ifile = open(finalfile, 'r')
lines = ifile.readlines()
ifile.close()
print "Number of peaks in table %d" % len(lines)

Output:

Number of peaks in table 434
Number of peaks in table 23

Categories: Algorithms | Crystal\DataHandling | DataHandling\Text

Source

C++ source: SaveLauenorm.cpp

C++ header: SaveLauenorm.h