source: sasview/docs/sphinx-docs/source/user/sasgui/guiframe/graph_help.rst @ 93b145a

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since 93b145a was 49148bb, checked in by smk78, 9 years ago

Add in guiframe related docs files

  • Property mode set to 100644
File size: 11.6 KB
RevLine 
[49148bb]1.. graph_help.rst
2
3.. This is a port of the original SasView html help file to ReSTructured text
4.. by S King, ISIS, during SasView CodeCamp-III in Feb 2015.
5
6
7Plotting Data/Models
8====================
9
10SasView generates three different types of graph window: one that displays *1D data*
11(ie, I(Q) vs Q), one that displays *1D residuals* (ie, the difference between the
12experimental data and the theory at the same Q values), and *2D color maps*.
13
14Graph window options
15--------------------
16
17.. _Invoking_the_graph_menu:
18
19Invoking the graph menu
20^^^^^^^^^^^^^^^^^^^^^^^
21
22To invoke the *Graph Menu* simply right-click on a data/theory plot, or click
23the *Graph Menu* (bullet list) icon in the toolbar at the bottom of the plot.
24Then select a menu item.
25
26How to Hide-Show-Delete a graph
27^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
28
29To expand a plot window, click the *Maximise* (square) icon in the top-right
30corner.
31
32To shrink a plot window, click the *Restore down* (square-on-square) icon in
33the top-right corner.
34
35To hide a plot, click the *Minimise* (-) icon in the top-right corner of the
36plot window.
37
38To show a hidden plot, select the *Restore up* (square-on-square) icon on the
39minimised window.
40
41To delete a plot, click the *Close* (x) icon in the top-right corner of the
42plot window.
43
44*NOTE! If a residuals graph (when fitting data) is hidden, it will not show up
45after computation.*
46
47Dragging a plot
48^^^^^^^^^^^^^^^
49
50Select the *Pan* (crossed arrows) icon in the toolbar at the bottom of the plot
51to activate this option. Move the mouse pointer to the plot. It will change to
52a hand. Then left-click and drag the plot around. The axis values will adjust
53accordingly.
54 
55To disable dragging mode, unselect the *crossed arrows* icon on the toolbar.
56
57Zooming In-Out on a plot
58^^^^^^^^^^^^^^^^^^^^^^^^
59
60Select the *Zoom* (magnifying glass) button in the toolbar at the bottom of
61the plot to activate this option. Move the mouse pointer to the plot. It will
62change to a cross-hair. Then left-click and drag the pointer around to generate
63a region of interest. Release the mouse button to generate the new view.
64
65To disable zoom mode, unselect the *Zoom* button on the toolbar.
66
67After zooming in on a a region, the *left arrow* or *right arrow* buttons on
68the toolbar will switch between recent views.
69
70*NOTE! If a wheel mouse is available scrolling the wheel will zoom in/out
71on the current plot (changing both axes). Alternatively, point at the numbers
72on one axis and scroll the wheel to zoom in/out on just that axis.*
73
74To return to the original view of the data, click the the *Reset* (home) icon
75in the toolbar at the bottom of the plot (see Resetting_the_graph_ for further details).
76
77Saving a plot image
78^^^^^^^^^^^^^^^^^^^
79
80To save the current plot as an image file, right click on the plot to bring up
81the *Graph Menu* (see Invoking_the_graph_menu_) and select *Save Image*.
82Alternatively, click on the *Save* (floppy disk) icon in the toolbar at the
83bottom of the plot.
84 
85A dialog window will open. Select a folder, enter a filename, choose an output
86image type, and click *Save*.
87
88The currently supported image types are:
89
90*  EPS (encapsulated postscript)
91*  EMF (enhanced metafile)
92*  JPG/JPEG (joint photographics experts group)
93*  PDF (portable documant format)
94*  PNG (portable network graphics)
95*  PS (postscript)
96*  RAW/RGBA (bitmap)
97*  SVG/SVGA (scalable vector graphics)
98*  TIF/TIFF (tagged iamge file)
99
100Printing a plot
101^^^^^^^^^^^^^^^
102
103To send the current plot to a printer, click on the *Print* (printer) icon in
104the toolbar at the bottom of the plot.
105
106.. _Resetting_the_graph:
107
108Resetting the graph
109^^^^^^^^^^^^^^^^^^^
110
111To reset the axis range of a graph to its initial values select *Reset Graph
112Range* on the *Graph Menu* (see Invoking_the_graph_menu_). Alternatively, use
113the *Reset* (home) icon in the toolbar at the bottom of the plot.
114
115Modifying the graph
116^^^^^^^^^^^^^^^^^^^
117
118From the *Graph Menu* (see Invoking_the_graph_menu_) it is also possible to
119make some custom modifications to plots, including:
120
121*  changing the plot window title
122*  changing the axis legend locations
123*  changing the axis legend label text
124*  changing the axis legend label units
125*  changing the axis legend label font & font colour
126*  adding/removing a text string
127*  adding a grid overlay
128
129Changing scales
130^^^^^^^^^^^^^^^
131
132This menu option is only available with 1D data.
133
134From the *Graph Menu* (see Invoking_the_graph_menu_) select *Change Scale*. A
135dialog window will appear in which it is possible to choose different
136transformations of the x (usually Q) or y (usually I(Q)) axes, including:
137
138*  x, x^2, x^4, ln(x), log10(x), log10(x^4)
139*  y, 1/y, ln(y), y^2, y.(x^4), 1/sqrt(y),
140*  log10(y), ln(y.x), ln(y.x^2), ln(y.x^4), log10(y.x^4)
141 
142A *View* option includes short-cuts to common SAS transformations, such as:
143
144*  linear
145*  Guinier
146*  X-sectional Guinier
147*  Porod
148*  Kratky
149
150For properly corrected and scaled data, these SAS transformations can be used
151to estimate, for example, Rg, rod diameter, or SANS incoherent background
152levels, via a linear fit (see Making_a_linear_fit_).
153
154Toggling scales
155^^^^^^^^^^^^^^^
156
157This menu option is only available with 2D data.
158
159From the *Graph Menu* (see Invoking_the_graph_menu_) select *Toggle Linear/Log
160Scale* to switch between a linear to log intensity scale. The type of scale
161selected is written alongside the colour scale.
162
1632D color maps
164^^^^^^^^^^^^^
165
166This menu option is only available with 2D data.
167
168From the *Graph Menu* (see Invoking_the_graph_menu_) select *2D Color Map* to
169choose a different color scale for the image and/or change the maximum or
170minimum limits of the scale.
171
172Getting data coordinates
173^^^^^^^^^^^^^^^^^^^^^^^^
174
175Clicking anywhere in the plot window will cause the current coordinates to be
176displayed in the status bar at the very bottom-left of the SasView window.
177 
178.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
179
180Dataset menu options
181--------------------
182
183.. _Invoking_the_dataset_menu:
184
185Invoking the dataset menu
186^^^^^^^^^^^^^^^^^^^^^^^^^
187
188From the *Graph Menu* (see Invoking_the_graph_menu_) highlight a plotted
189dataset.
190
191Getting data info
192^^^^^^^^^^^^^^^^^
193
194In the *Dataset Menu* (see Invoking_the_dataset_menu_), highlight a data set
195and select *DataInfo* to bring up a data information dialog panel for that
196data set.
197
198Saving data
199^^^^^^^^^^^
200
201In the *Dataset Menu* (see Invoking_the_dataset_menu_), select *Save Points as
202a File* (if 1D data) or *Save as a file(DAT)* (if 2D data). A save dialog will
203appear.
204
2051D data can be saved in either ASCII text (.TXT) or CanSAS/SASXML (.XML)
206formats (see :ref:`Formats`).
207
2082D data can only be saved in the NIST 2D format (.DAT) (see :ref:`Formats`).
209
210.. _Making_a_linear_fit:
211
212Making a linear fit
213^^^^^^^^^^^^^^^^^^^
214
215Linear fit performs a simple ( y(x)=ax+b ) linear fit within the plot window.
216
217In the *Dataset Menu* (see Invoking_the_dataset_menu_), select *Linear Fit*. A
218fitting dialog will appear. Set some initial parameters and data limits and
219click *Fit*. The fitted parameter values are displayed and the resulting line
220calculated from them is added to the plot.
221
222This option is most useful for performing simple Guinier, XS Guinier, and
223Porod type analyses, for example, to estimate Rg, a rod diameter, or incoherent
224background level, respectively.
225
226The following figure shows an example of a Guinier analysis using this option
227
228.. image:: guinier_fit.png
229
230Removing data from the plot
231^^^^^^^^^^^^^^^^^^^^^^^^^^^
232
233In the *Dataset Menu* (see Invoking_the_dataset_menu_), select *Remove*. The
234selected data will be removed from the plot.
235
236*NOTE! This action cannot be undone.*
237
238Show-Hide error bars
239^^^^^^^^^^^^^^^^^^^^
240
241In the *Dataset Menu* (see Invoking_the_dataset_menu_), select *Show Error Bar*
242or *Hide Error Bar* to switch between showing/hiding the errors associated
243with the chosen dataset.
244
245Modify plot properties
246^^^^^^^^^^^^^^^^^^^^^^
247
248In the *Dataset Menu* (see Invoking_the_dataset_menu_), select *Modify Plot
249Property* to change the size, color, or shape of the displayed marker for the
250chosen dataset, or to change the dataset label that appears on the plot.
251
252.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
253
2542D data averaging
255-----------------
256
257Purpose
258^^^^^^^
259
260This feature is only available with 2D data.
261
2622D data averaging allows you to perform different types of averages on your
263data. The region to be averaged is displayed in the plot window and its limits
264can be modified by dragging the boundaries around.
265
266How to average
267^^^^^^^^^^^^^^
268
269In the *Dataset Menu* (see Invoking_the_dataset_menu_), select one of the
270following averages
271
272*  Perform Circular Average
273*  Sector [Q view]
274*  Annulus [Phi view]
275*  Box sum
276*  Box averaging in Qx
277*  Box averaging on Qy
278
279A 'slicer' will appear (except for *Perform Circular Average*) in the plot that
280you can drag by clicking on a slicer's handle. When the handle is highlighted
281in red, it means that the slicer can move/change size.
282
283*NOTE! The slicer size will reset if you try to select a region greater than
284the size of the data.*
285
286Alternatively, once a 'slicer' is active you can also select the region to
287average by bringing back the *Dataset Menu* and selecting *Edit Slicer
288Parameters*. A dialog window will appear in which you can enter values to
289define a region or select the number of points to plot (*nbins*).
290
291A separate plot window will also have appeared, displaying the requested
292average.
293
294*NOTE! The displayed average only updates when input focus is moved back to
295that window; ie, when the mouse pointer is moved onto that plot.*
296
297Selecting *Box Sum* automatically brings up the 'Slicer Parameters' dialog in
298order to display the average numerically, rather than graphically.
299
300To remove a 'slicer', bring back the *Dataset menu* and select *Clear Slicer*.
301
302Unmasked circular average
303^^^^^^^^^^^^^^^^^^^^^^^^^
304
305This operation will perform an average in constant Q-rings around the (x,y)
306pixel location of the beam center.
307
308Masked circular average
309^^^^^^^^^^^^^^^^^^^^^^^
310
311This operation is the same as 'Unmasked Circular Average' except that any
312masked region is excluded.
313
314Sector average [Q View]
315^^^^^^^^^^^^^^^^^^^^^^^
316
317This operation averages in constant Q-arcs.
318
319The width of the sector is specified in degrees (+/- |delta|\|phi|\) each side
320of the central angle (|phi|\).
321
322Annular average [|phi| View]
323^^^^^^^^^^^^^^^^^^^^^^^^^^^^
324
325This operation performs an average between two Q-values centered on (0,0),
326and averaged over a specified number of pixels.
327
328The data is returned as a function of angle (|phi|\) in degrees with zero
329degrees at the 3 O'clock position.
330
331Box sum
332^^^^^^^
333
334This operation performs a sum of counts in a 2D region of interest.
335
336When editing the slicer parameters, the user can enter the length and the width
337the rectangular slicer and the coordinates of the center of the rectangle.
338
339Box Averaging in Qx
340^^^^^^^^^^^^^^^^^^^
341
342This operation computes an average I(Qx) for the region of interest.
343
344When editing the slicer parameters, the user can control the length and the
345width the rectangular slicer. The averaged output is calculated from constant
346bins with rectangular shape. The resultant Q values are nominal values, that
347is, the central value of each bin on the x-axis.
348
349Box Averaging in Qy
350^^^^^^^^^^^^^^^^^^^
351
352This operation computes an average I(Qy) for the region of interest.
353
354When editing the slicer parameters, the user can control the length and the
355width the rectangular slicer. The averaged output is calculated from constant
356bins with rectangular shape. The resultant Q values are nominal values, that
357is, the central value of each bin on the x-axis.
358
359.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
360
361.. note::  This help document was last changed by Steve King, 01May2015
Note: See TracBrowser for help on using the repository browser.