source: trunk/doc/liveplot.html @ 785

Last change on this file since 785 was 785, checked in by toby, 13 years ago

# on 2004/04/27 14:49:32, toby did:
document ability to scan zoom region with arrow keys

  • Property rcs:author set to toby
  • Property rcs:date set to 2004/04/27 14:49:32
  • Property rcs:lines set to +10 -1
  • Property rcs:rev set to 1.15
  • Property rcs:state set to Exp
  • Property svn:keywords set to Author Date Revision Id
File size: 28.7 KB
Line 
1<html>
2<head>
3   <title>EXPGUI -- LIVEPLOT/BKGEDIT</title>
4   <meta name="keywords" content="crystallography, Rietveld, diffraction,
5   GSAS, EXPGUI">
6</HEAD>
7<style>
8A:link {text-decoration:none}
9A:vlink {text-decoration:none}
10</style>
11
12<BODY BGCOLOR="#FFFFFF"
13      topmargin="0" leftmargin="0" marginwidth="0" marginheight="0" 
14      text="#000000" link="#0033ff" vlink="#0033ff" alink="#0033ff">
15
16<?
17   include("/var/www/include/navigation.inc");
18   include("/var/www/include/utility.inc");
19?>
20<blockquote><font face="arial, helvetica, sans-serif">
21
22<TABLE BORDER BGCOLOR="#FFFF40" ALIGN=RIGHT>
23<TR><TH><A  Href="expgui.html">EXPGUI top</A> 
24</TH><TH><A Href="excledt.html">Next page<BR>(EXCLEDT)</A>
25</TH><TH><A Href="expguic.html">Previous page</A>
26</TH></TR></TABLE><BR CLEAR=ALL>
27
28<center><h1>
29<HR noshade width="75%" size="2" align="center">
30EXPGUI Utilities (1),<BR>LIVEPLOT and BKGEDIT
31<HR noshade width="75%" size="2" align="center">
32</h1></center>
33This page documents the LIVEPLOT and BKGEDIT utility programs
34in the EXPGUI package.
35LIVEPLOT and BKGEDIT are actually the same program, but perform
36different functions, depending on how they are invoked.
37LIVEPLOT is used to display the quality of the diffraction fit, while
38BKGEDIT is used to fit a background function to fixed background points
39that have been input by the user.
40<P>
41Both LIVEPLOT and BKGEDIT get the current diffraction information
42by running the GSAS TCLDUMP program, if installed, or
43the GSAS HSTDUMP otherwise. The TCLDUMP program has been optimized for use
44with LIVEPLOT and allows LIVEPLOT to offer a number of extra
45options that are not available when HSTDUMP is used. Since TCLDUMP has been
46included in GSAS since April of 2000, the following documentation assumes
47that TCLDUMP is installed.
48
49<a name="liveplot"></a>
50<H3>LIVEPLOT</H3>
51LIVEPLOT is started by pressing the LIVEPLOT button on the toolbar
52or via the Graphs/liveplot menu item.
53<P>
54Some of the features available in LIVEPLOT are:
55<UL>
56<LI>The plot is updated automatically after each refinement run
57<LI>The plot can be "zoomed-in", by clicking on the corners of the
58area to be magnified and "zoomed-out" using the
59right mouse button (Mac: Apple+click)
60<LI>
61The units used for plotting histograms can be selected. Choices are:
62native units (2Theta/TOF/KeV); d-space (A) or Q (A<sup>-1</sup>)
63<LI>
64The background (fixed plus fitted) can be plotted or can be subtracted.
65<LI>
66Reflection tickmarks can be displayed in a variety of formats
67<LI>
68LIVEPLOT can be coupled to the LOGIC or CMPR programs, so that
69peak positions from an ICDD entry or for an arbitrary unit cell and
70spacegroup can be shown superimposed on the "Rietveld plot."
71<LI>
72<IMG SRC="note.gif" alt="Note!">
73Reflection indices (<I>hkl</I> values) can be shown for tickmarks
74<LI>
75<IMG SRC="note.gif" alt="Note!">
76The cumulative chi<sup>2</sup> function can be plotted.
77<LI>
78<IMG SRC="note.gif" alt="Note!">
79The cursor position can be displayed
80<LI>
81<IMG SRC="note.gif" alt="Note!">
82Plots can be <a href="#export">exported to obtain publication-quality
83graphics.</a>
84</UL>
85
86<a name="bkgedit"></a>
87<H3>BKGEDIT</H3>
88<IMG SRC="note.gif" alt="Note!">
89BKGEDIT is used to fit a background function to a set of points
90selected by the user.
91For most refinements, this is not needed,
92as it is possible to simply select a background
93function (I find that the type 1 function,
94shifted Chebyschev polynomials, works well)
95and then refine, adding terms until a good fit is obtained.
96On occasion, poor initial fits are obtained in this manner. This is
97most common in cases where large numbers of peaks are poorly fit. Since
98significant sections of the data are not well fit, the refinement results in
99an unreasonable background function, because this yields better agreement
100with the observed data.
101In these cases,
102it may be best to fix the background to follow a "reasonable" curve in the
103initial stages and then refine the background in the final stages of
104refinement, when a good model has been obtained.
105<P>
106The BKGEDIT program, as shown below, is used to input a set a background
107points via the mouse. The points are then used to determine a type 1
108(Chebyschev) background function that fits the input background points. These
109terms can then be saved in the experiment file creating a background that
110is good enough for the initial stages of refinement and that can be
111refined once the model is adequate for the task.
112<IMG SRC="note.gif" alt="Note!">
113BKGEDIT can be used to fit GSAS background functions 1-6 (though
114for most purposes only type 1 is needed.)
115<P>
116<IMG SRC="b1.gif" align=TEXTOP alt="BKGEDIT screen image">
117<H4>Steps in fitting a background function</H4>
118The BKGEDIT program is started from
119via the Powder/bkgedit menu item or by pressing the
120"Fit Background Graphically" button on the
121<A href="expgui3.html#EditBackground">"Edit Background"</A>
122dialog box (invoked from the "Edit Background" button on the
123<A href="expgui3.html">Histogram pane</A>.)
124toolbar
125or
126<OL>
127<LI><a href="#zoom">Zoom in</a> on the lower intensity section of the
128plot, so that the background is clearly discernible. In some cases, the
129data will need to be handled in sections.
130<LI>Press the "Add" button to add background points.
131Note the cursor changes from cross-hairs to an arrow,
132when the "Add" button is pressed.
133<LI>Move the mouse to the first location
134where a background point will be added and click with the left
135mouse button. A magenta triangle will appear at the location.
136Points can be added in any order. It is best to make sure that the fixed points
137are placed over the entire range of the data, e.g. near the maximum and minimum
138data points in TOF, 2theta, etc.
139<DL><DL>
140Note that it is advisable to place many background points in areas where
141the background is changing rapidly (where the background is most bumpy).
142</DL></DL>
143As background points are entered, they are saved in a file named
144<I>EXPNAM</I><font face="courier">.bkg</font><I>N</I>, where
145<I>EXPNAM</I> is the experiment name and <I>N</I> is the histogram number.
146If BKGEDIT is restarted at some later time, these points are reread.
147<LI>If any points are placed in incorrect positions, they can be deleted by
148pressing the "Delete" button. The mouse cursor changes to a circle. When
149the mouse left clicked, the fixed background point closest to the mouse
150position (which may be outside the zoom range) is deleted.
151<LI>Background points can also be edited by entering numbers into the
152"Background points" area.
153<LI>After enough background points have been entered, the
154"Fit" button turns from gray to black. When pressed, the selected
155background function is fitted
156and the resulting curve is shown as a blue dashed line.
157<DL><DL>
158<LI>It is suggested that you start with relatively few
159terms and add terms and background points as needed.
160Note that the maximum number of increases as
161more background points are entered.
162<LI>Editing the terms manually is possible. The curve is reevaluated as
163changes are made.
164<LI>For the type 3 background function (radial distribution function),
165the R terms are listed separately from the other
166background terms. These R (radii) values must be entered manually and
167are not refined.
168</DL></DL>
169<LI>Once a good background function is determined, it can be saved in the
170experiment file by pressing the "Save in EXP file & Exit" button. This will
171set the background type, and save the terms.
172It will also turn off
173the background refinement flag for the appropriate histogram so that the
174terms are not refined inadvertently.
175</OL>
176
177<P>
178Note that POWPREF must be run at least once before BKGEDIT can be used,
179however, use of
180GENLES before BKGEDIT is optional. If the data range is changed, for example
181by excluding a section of the data at the lower end, or changing tmax (dmin),
182the Chebyschev polynomial terms must change to generate the same
183background values, so both POWPREF and BKGEDIT should be rerun to
184regenerate the Chebyschev terms.
185
186<H4>Why not use fixed background points?</H4>
187I personally feel that
188a refined background function is preferrable to use of a fixed model,
189if at all possible.
190One reason for this is that Rietveld refinements usually achieve better fits
191when the background is optimized. A second reason refining the background
192provides a
193feel for the interaction between background values and displacement
194(thermal) parameters.
195Usually, background and displacement parameters are fairly independent, but
196for some materials, where the high Q (high 2theta) portion of the pattern
197has many completely overlapped peaks, it is impossible to uniquely
198determine where the
199background should be placed, either by refinement or by manual placement.
200Under these circumstances, the background should be refined with the
201displacement parameters fixed at an appropriate value for the material. The
202background should then be fixed for all future refinements
203and the displacement parameters can then be refined. <I>Of course this
204means you have predjudiced the refinement to result in the expected
205average displacement parameter and this </I><B>must</B><I> be noted
206any publication. However, if this is necessary, the data simply do not
207contain sufficient information to independently determine
208background and displacement parameters. Use of fixed background points
209would not demonstrate this and would lead the researcher to a false
210sense of security (or fear, if the values are unreasonable)
211that the displacement parameters actually mean something.</I>
212<P>
213If you still want to use fixed background points, despite this tirade,
214be sure to set the estimated
215error on those points to be 0.0. Use of non-zero estimated errors, can
216result in artificially lowered R-factors and chi-squared values.
217In one test, I was able to lower the R<sub>wp</sub> and
218reduced chi<sup>2</sup> values,
219from the correct values of 0.042 and 3.0, respectively, to misleading
220values of 0.036 and 0.8,
221respectively. [As expected, the R(F<sup>2</sup>) stayed constant at 0.045
222with the different fixed background errors;
223FYI, refining the background caused R(F<sup>2</sup>) to drop to 0.036,
224so I would consider the refined background to be better.]
225<P>
226If the background is so truly irregular that only use of fixed background
227points will do,
228BKGEDIT can be used to generate these fixed background points.
229The file used by BKGEDIT to save these points,
230<I>EXPNAM</I><font face="courier">.bkg</font><I>N</I>,
231will define the background points if read directly into EXPEDT
232by typing "@R" at the initial prompt in EXPEDT:
233<FONT FACE="COURIER"><PRE>
234   Is this the file you wish to use? (?,D,K,Q,R,Y) ><u>@r</u>
235</PRE></FONT>
236prompt and then supplying the name of the file, in response to the next prompt:
237<FONT FACE="COURIER"><PRE>
238   Enter the name of your macro file: <u>GARNET.bkg1</u>
239</PRE></FONT>
240Doing this will cause the background points you entered into BKGEDIT to
241be used in GSAS
242fixed background points. If you do this you do not want to save the
243fitted background function as well, as this would effectively subtract
244double the desired background.
245Note that GSAS allows simultaneous use of
246both fixed and a refined background;
247this is seldom done.
248
249<hr><h2>LIVEPLOT/BKGEDIT Features</h2>
250<B>Plot contents:</B>
251Reflection markers can be placed using the File/Tickmarks menu item
252<IMG SRC="note.gif" alt="Note!">or by pressing the
253"1" key for phase 1, "2" for phase 2,... Note that many attributes
254for reflection markers can be edited using
255Options/<a href="#configTick">Configure Tickmarks</a>
256
257<P>
258<IMG SRC="note.gif" alt="Note!">
259If more than one histogram is available to plot, it is possible to cycle
260between the histograms by pressing the "n" or "N" (for next) key.
261<P>
262<a name="zoom"></a>
263<B>Plot zooming:</B>
264When the left (usual) mouse button is pressed, this defines one corner
265of a region to be magnified, as is shown to the right.
266If the mouse is then moved, the diagonal
267corner of this magnification region is defined. When the left mouse button
268is pressed a second time, the selected section of the plot is magnified to
269fill the entire plot.
270<P>
271<img SRC="mzoom.gif" align=RIGHT alt="LIVEPLOT manual zoom">
272Zoom settings are saved.
273If the right mouse button is pressed, the previous zoom setting is used,
274so that the left mouse button is used to "zoom in" and the right mouse
275button is used to "zoom out." Note, on the Macintosh, hold down the
276Apple button while using the [only] mouse button to simulate a right-click.
277
278<P>
279<IMG SRC="note.gif" alt="Note!">
280Zoom settings can also be entered manually by pressing the "Z" key. This
281opens a dialog, as is shown to the right, where the x- or y-axis range
282can be specified. Any value that is not specified is set to the maximum
283or minimum for the entire dataset. It is possible to zoom further in using
284the mouse, but to zoom out beyond the manual zoom limits, the "reset" button
285on the manual zoom menu must be used.
286<P>
287<IMG SRC="new.gif" alt="New!">
288To shift the zoom region around,
289the right and left arrow keys can be used to shift the
290region 10 % to the left or right.
291Likewise,
292the up and down arrow keys can be used to shift the region up or down by 10 %.
293Holding down the control key down while pressing these keys increases
294the amount of the shift to 100 %.
295<P>
296<a name="LiveCursor"></a>
297<img SRC="cursor.gif" align=RIGHT alt="LIVEPLOT live cursor">
298<IMG SRC="note.gif" alt="Note!">
299<B>Cursor Display:</B>
300Pressing the "L" (or "l") key, or using the Option/Show Cursor Position
301menu button causes the position of the cursor (mouse position)
302in plot to be shown. The coordinates are listing in a small area below
303the plot. The position display is updated as the mouse is moved. The
304same key, menu button, or the button labeled "Close cursor display" can be
305used to remove the display.
306<P>
307<br clear=all>
308<h2>Features in LIVEPLOT only</h2>
309<img SRC="lz.gif" BORDER=3 align=RIGHT alt="LIVEPLOT Screen snapshot">
310<a name="Cchi2"></a>
311<B>The cumulative chi<sup>2</sup></B>
312function was first suggested by
313Bill David as a way to see which reflections have the greatest influence on
314chi<sup>2</sup> [W.I.F. David, <I>Accuracy in Powder Diffraction-III</I>, 2001].
315It is defined for point j as
316<IMG SRC="cchi2.gif" alt="equation for cumulative chi2 function" ALIGN=TOP>
317where y<sub>obs,i</sub> and y<sub>calc,i</sub> are the observed and computed
318data points and sigma<sub>i</sub> is the expected error. Thus, the statistically
319expected value for
320[(y<sub>obs,i</sub>-y<sub>calc,i</sub>)/sigma<sub>i</sub>]<sup>2</sup> is 1
321and this function should rise in a smooth line if all points are fitted as
322statistically expected.
323<P>
324In the plot to the right, the cumulative chi<sup>2</sup> function is shown in
325purple. Note that first peak is not well fit, but the low angle "shoulder" is
326as important as the peak misfitting, with respect to the chi<sup>2</sup>.
327<br clear=all>
328<P>
329<img SRC="lind.gif" BORDER=3 align=RIGHT alt="LIVEPLOT Screen snapshot">
330<B>Reflection indices</B>
331are be displayed by pressing "H" or "h" while the
332mouse is near a reflection (holding the shift key while
333pressing the left mouse button also works, but sometimes interferes with the
334zoom feature).
335Pressing "A" or "a" shows all reflections in the displayed region.
336The indices are shown
337on the screen for phases with tickmarks (as shown to the right).
338Indices are listed in the "Separate window for <I>hkl</I> labels"
339(as seen below) for all phases, regardless of the tickmark settings.
340Displayed indices will remain on the screen for a preset time and
341then will be deleted; alternately, pressing "D" or "d" deletes the hkl labels.
342Several aspects of reflection labeling can be customized,
343see the <a href="#hklOpts">HKL labeling options</a> for further information.
344
345<img SRC="lind1.gif" align=LEFT alt="LIVEPLOT Screen snapshot">
346
347<br clear=all>
348<P>
349<a name="export"></a>
350<IMG SRC="note.gif" alt="Note!">
351<B>Export plot options</B>
352<UL><LI>
353The plot can be exported to
354<A HREF="http://www.nist.gov/cgi-bin/exit_nist.cgi?url=http://plasma-gate.weizmann.ac.il/Grace/">Grace</A>, WYSIWYG 2D plotting tool for X-Windows
355that produces publication-quality graphics. Many UNIX users know
356this program under a previous name, xmgr.
357The export is implemented
358by producing an ASCII file with instructions that
359creates a plot with similar formatting to what appears on the
360screen in LIVEPLOT/BKGEDIT. However, the output quality from
361Grace is much higher quality. Further, Grace
362can be used to enhanced and annotate the plot further.
363<LI>
364For use in many other graphics programs, LIVEPLOT will produce a
365"comma separated variable" data file with the data displayed on the screen.
366The user will need to read this in,
367set line styles and scaling, etc., but this does provide an option for
368generating high-quality graphics for presentations and publications.
369<LI>LIVEPLOT will produce PostScript versions of the plot on the screen,
370but the quality is rather low (this is a limitation of the BLT graphics
371package).
372</UL>
373
374<hr><h2>LIVEPLOT/BKGEDIT Menu Contents</h2>
375A few of these options are omitted from BKGEDIT.
376<img SRC="lm1.gif" align=RIGHT alt="LIVEPLOT Menu">
377<H3>File Menu</H3>
378<DL><DL>
379<DT>Tickmarks
380<DD>Checkbuttons are provided for each phase to determine if tick marks
381will be shown.
382<IMG SRC="note.gif" alt="Note!">
383Tickmarks can also be
384toggled by pressing the
385"1" key for phase 1, "2" for phase 2,...
386Also see the Options/<a href="#configTick">Configure Tickmarks</a>
387menu item for information
388on tickmarks.
389<DT>Histogram
390<DD>This allows a histogram to be selected to be loaded
391<DL><DL>
392<IMG SRC="note.gif" alt="Note!">
393It is also possible to advance
394between the histograms by pressing the "n" or "N" (for next) key.
395</DL></DL>
396<DT>Update Plot
397<DD>The causes LIVEPLOT to read read the current histogram again from
398the datafile
399<DT>Export Plot
400<DD>This offers options for exporting the plot in multiple formats.
401I am hoping to add more export formats eventually.
402<DL><DL>
403<DT>to PostScript
404<DD>Creates a <I>low quality</I> PostScript file containing the LIVEPLOT
405output. See the Options/"Set PS output" button for where the file is created.
406Most unix systems are capable or printing PostScript files.
407On Windows, a program such ghostview may be needed to translate the
408PostScript to a format that can be viewed or printed.
409<A name="grace">
410<DT>to Grace
411<IMG SRC="note.gif" alt="Note!">
412<DD>Plots can be exported to
413<A HREF="http://www.nist.gov/cgi-bin/exit_nist.cgi?url=http://plasma-gate.weizmann.ac.il/Grace/">Grace</A>, WYSIWYG 2D plotting tool for X-Windows
414that produces publication-quality graphics.
415After the plot is exported, it can be further
416enhanced and annotated in grace.
417</DL></DL>
418<DT>Quit
419<DD>Exits BKGEDIT/LIVEPLOT.
420</DL></DL>
421<br clear=all>
422<img SRC="lm2.gif" align=RIGHT alt="LIVEPLOT Menu">
423<H3>Options Menu</H3>
424<DL><DL>
425<a name="configTick"></a>
426<DT>Configure Tickmarks<DD>
427This submenu provides options that controls how tickmarks are displayed.
428<DL><DL>
429<DT>Auto locate<DD>
430When this option is selected, tickmarks are placed in different positions
431for each phase, automatically, similar to how tickmarks are shown in POWPLOT.
432<DT>Manual Placement<DD>
433Tickmarks are drawn at specific heights that can be set for each phase
434(see below). The default
435is for lines to be draw from "-Inf" to "Inf", which creates lines from the
436bottom to the top of the plot.
437<DT>Label by name
438<IMG SRC="note.gif" alt="Note!">
439<DD>
440By default, a label "Phase1",... is displayed in the legend when tickmarks
441for that phase are displayed. When this button is pressed, the first
44220 characters of each phase name (phase title) are used instead. This
443label can be edited, as described in the next paragraph.
444<DT>Phase <I>n</I> opts<DD>
445The options for each phase allow the line to be changed between
446solid and dashed, color of the line can be specified and
447the vertical placement of the tickmarks can be specified. The
448"Show Reflections" flag,
449set in the File/Tickmarks menu,
450as well as the label used for the phase can also be changed here.
451
452</DL></DL>
453<DT>Obs Symbol (Symbol Type)
454<DD>This brings up a menu where the symbol type and size for the
455observed data points (and for BKGEDIT, the fixed background points)
456can be selected.
457<DT>Symbol Color
458<DD>The colors for all the displayed lines and symbols can be changed here.
459<DT>X units
460<DD>The x units can be selected here. The choices are
461"as collected" (2Theta/TOF/KeV), d-space (A) or Q (A<sup>-1</sup>)
462<DT>Y units
463<DD>The intensity values can be normalized by the incident spectrum
464(for energy dispersive methods).
465</DL></DL>
466<br clear=all>
467<img SRC="lm3.gif" align=RIGHT alt="LIVEPLOT menu">
468<a name="hklOpts"></a>
469<DL><DL>
470<DT>HKL labeling
471<DD>This brings up a menu that selects
472<UL><LI>Erase time:
473how long in seconds that <I>hkl</I> values are shown
474before they are erased (0 means that they are not erased),
475<LI>Label size: the size of the
476labels in pixels,
477<LI>Search Region: only reflections within this number of pixels of the mouse,
478when the "h" key is pressed (if any) are labeled,
479<LI>Separate window: when this
480option is selected, reflection labels are shown in a text window
481</UL>
482<DT>Subtract background
483<DD>The background is always shown, even when subtracted
484<DT>Include legend
485<DD>The legend is the optional box in the upper left that defines the
486plot entries
487<DT>Show [Hide] Cursor Position
488<DD>This turns <a href="#LiveCursor">Cursor position display</a> on and off.
489<DT>Set PS output
490<DD>For UNIX this allows the file to be sent directly to a printer
491or can be saved in a file. For Windows, a file must be written.
492<DT>Set screen font
493<DD>This option is used to control the font used for menus, graphics and
494other aspects of windows.
495<DT>Raise on update
496<DD>This causes the plot to be placed on top of other windows, if partially
497obscured, when the plot is updated. At this time, this option does not
498work in Windows-NT and -2000.
499<DT>Cumulative Chi2
500<DD>The causes the Cumulative chi<sup>2</sup> function to be displayed
501(as <a href="#Cchi2">presented above</a>).
502<DT>Save Options
503<DD>Causes many of the options set in this menu to be saved in the
504<FONT FACE="COURIER">.gsas_config</FONT> 
505(or <FONT FACE="COURIER">c:\gsas.config</FONT>) file.
506</DL></DL>
507<br clear=all>
508
509<P>
510<hr><H2>Customization of LIVEPLOT & BKGEDIT</H2><A NAME="customize"></A>
511The <FONT FACE="COURIER">localconfig</FONT> and
512<FONT FACE="COURIER">.gsas_config</FONT> 
513(or <FONT FACE="COURIER">c:\gsas.config</FONT>)
514files are read, if present.
515The following variables control how LIVEPLOT, and in most cases BKGEDIT,
516function and can be
517customized by changing their values in the
518<FONT FACE="COURIER">localconfig</FONT> and
519<FONT FACE="COURIER">.gsas_config</FONT> 
520(or <FONT FACE="COURIER">c:\gsas.config</FONT>)
521files.
522<DL><DL>
523<DT><FONT FACE="COURIER">peakinfo(flag<i>n</i>)</FONT><DD>
524These variables define if peak positions will be shown
525for reflections in phase "<i>n</i>". Reflections will be shown if
526the value is non-zero.
527
528<DT><FONT FACE="COURIER">peakinfo(color<i>n</i>)</FONT><DD>
529These variables define the default colors for
530reflections in phase "<i>n</i>"
531
532<DT><FONT FACE="COURIER">peakinfo(dashes<i>n</i>)</FONT><DD>
533These variables define if peaks will be dashed for
534reflections in phase "<i>n</i>" (UNIX only). Lines will be dashed if
535the value is non-zero.
536
537<DT><FONT FACE="COURIER">peakinfo(min<i>n</i>) and peakinfo(max<i>n</i>)</FONT><DD>
538These variables dictate the placement vertical position for reflection
539markers, when manually placed (see expgui(autotick), below). To draw
540to the edge of the screen, use -Inf and Inf.
541</DL></DL>
542
543The following variables are written to
544<font face="courier">.gsas_config</font> 
545(or <FONT FACE="COURIER">c:\gsas.config</FONT>)
546when
547"Save Options" is used. These variables are all set from the GUI and therefore
548do not need to be edited manually.
549
550<DL><DL>
551<DT><FONT FACE="COURIER">graph(printout)</FONT><DD>
552This is set to 1 if PostScript files
553will be printed and 0 if they will be written to disk (for Windows all
554files should be written to disk).
555
556<DT><FONT FACE="COURIER">graph(outname)</FONT><DD>
557This is the default for the file name used
558when PostScript files will be written to disk.
559
560<DT><FONT FACE="COURIER">graph(outcmd)</FONT><DD>
561This is the default for the command used
562to print PostScript files (Unix only).
563
564<DT><FONT FACE="COURIER">graph(legend)</FONT><DD>
565Sets the default value for display of the legend in LIVEPLOT and WIDPLT.
566
567<DT><FONT FACE="COURIER">graph(autoraise)</FONT><DD>
568This option shows up in the options menu item as "Raise on update."
569When set to non-zero, the LIVEPLOT window is raised
570(placed on top of any other overlapping) windows
571each time it is updated.
572This option does not seem to work in Windows-NT, but this may depend on
573the version of Tcl/Tk.
574
575<DT><FONT FACE="COURIER">peakinfo(obssym)</FONT><DD>
576Symbol for observed data points. Valid choices are square, circle, diamond,
577plus, cross, splus and scross.
578
579<DT><FONT FACE="COURIER">peakinfo(obssize)</FONT><DD>
580Size for the symbol for observed data points. A value of 1 corresponds to about 1/8 inch
581(about 3 mm).
582
583<DT><FONT FACE="COURIER">expgui(pixelregion)</FONT><DD>
584When hkl values are loaded (using tcldump) and reflections are labeled, reflections
585can be labeled using a Shift-Left-Mouse click. All labeled reflections within expgui(pixelregion)
586pixels of the mouse position are assumed to be overlapped and are labeled.
587
588<DT><FONT FACE="COURIER">expgui(fadetime)</FONT><DD>
589The time in seconds before reflection labels are removed. A value of zero means that reflections
590must be deleted manually (Shift-Right-Mouse).
591(Mac: Shift+Apple+click)
592<DT><FONT FACE="COURIER">expgui(lblfontsize)</FONT><DD>
593A size for reflections labels in pixels.
594
595<DT><FONT FACE="COURIER">expgui(hklbox)</FONT><DD>
596If this variable is non-zero, reflection indices are shown in a box.
597
598<DT><FONT FACE="COURIER">expgui(autotick)</FONT><DD>
599If this variable is non-zero, reflection markers positions are
600set automatically.
601</DL></DL>
602<P>
603<hr><H2>Interfacing External Programs</H2>
604<IMG SRC="new.gif" alt="New!">
605<B>Combining LIVEPLOT with CMPR & LOGIC</B>
606If you have the
607<A HREF="http://www.ncnr.nist.gov/programs/crystallography/software/cmpr">
608CMPR/LOGIC</A>
609programs installed on your computer, you can use superimpose on the
610GSAS results the peaks for an arbitrary unit cell.
611If you have the
612<A HREF="http://www.nist.gov/cgi-bin/exit_nist.cgi?url=http://www.icdd.com/products/overview.htm">
613ICDD-JCPDS PDF-2 powder diffraction database</a>,
614you can also superimpose entries from this database on the
615GSAS results displayed in LIVEPLOT.
616<P>
617When the CMPR/LOGIC program is installed in the same location
618as the GSAS package (<i>e.g.</i> 
619<font face="courier">/home/gsas</font> & 
620<font face="courier">/home/cmpr</font>
621or <font face="courier">C:\DIFRC\GSAS</font> & 
622<font face="courier">C:\DIFRC\CMPR</font>) or if
623the CMPR/LOGIC programs are loaded into standard locations
624(<font face="courier">/usr/local/cmpr</font> or
625<font face="courier">~/cmpr</font> for Unix and Mac OSX or
626<font face="courier">c:\cmpr</font> or
627<font face="courier">c:\Program files\cmpr</font> for Windows),
628the LIVEPLOT program will locate both programs and add an extra menu labeled
629"Peak Gen" to the menu bar. If the CMPR program is not located automatically,
630you may customize this location by specifying a value for
631Tcl/Tk variable cmprdir by including a line such as this:
632<PRE>
633          set cmprdir C:/ncnrpkg/cmpr
634</PRE>
635 in the <FONT FACE="COURIER">localconfig</FONT>,
636<FONT FACE="COURIER">.gsas_config</FONT> 
637or <FONT FACE="COURIER">c:\gsas.config</FONT> files
638[note that forward slashes ("/") should be used here, even for windows.]
639
640<P>
641The "Peak Gen" menu will have either or both of two entries
642"Display a cell" and "Plot ICDD Entry", depending on what
643software is located. The
644"Display a cell" option produces a window similar to the
645<A href="http://www.ncnr.nist.gov/xtal/software/cmpr/doc/cmprdoc.html#editcell">
646Edit Cell feature in CMPR</A>
647where allowed reflection positions are displayed for a set of unit cell
648parameters and optionally a space group or extinction conditions.
649The "Plot ICDD Entry" provides a window similar to the
650<A href="http://www.ncnr.nist.gov/xtal/software/cmpr/doc/cmprdoc.html#editcell">
651LOGIC interface in CMPR</A>
652where ICDD searches may be conducted. From the resulting list of matches,
653selected entries may be displayed.
654<P>
655Note that these routines display peak positions in units of 2Theta, Q or
656d-space. If you are using TOF or EDS data, you must select Q or d-space
657display in LIVEPLOT. If you are using 2Theta, you must supply the correct
658wavelength.
659<P>
660Note that a version of both EXPGUI and CMPR/LOGIC from November 2003 or later
661must be used for these features to work.
662
663</UL>
664<hr>
665<TABLE BORDER BGCOLOR="#FFFF40" ALIGN=RIGHT>
666<TR><TH><A  Href="expgui.html">EXPGUI top</A>
667</TH><TH><A Href="excledt.html">Next page<BR>(EXCLEDT)</A>
668</TH><TH><A Href="expguic.html">Previous page</A>
669</TH></TR></TABLE>
670
671<P><font size=-1><A HREF="MAILTO:crystal@NIST.gov?subject=WWW page <?=$PHP_SELF?>">Comments, corrections or questions: crystal@NIST.gov</A></font><BR>
672<font size=-1><? lastmod(); ?> </font>
673<br>
674$Revision: 785 $ $Date: 2009-12-04 23:11:59 +0000 (Fri, 04 Dec 2009) $
675</blockquote>
676</body>
677</html>
Note: See TracBrowser for help on using the repository browser.