Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
mantid
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mantidproject
mantid
Commits
699e1011
Commit
699e1011
authored
9 years ago
by
Marina Ganeva
Browse files
Options
Downloads
Patches
Plain Diff
Fixed doctests for TOFTOFMergeRuns.
parent
454523d2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/source/algorithms/TOFTOFMergeRuns-v1.rst
+10
-6
10 additions, 6 deletions
docs/source/algorithms/TOFTOFMergeRuns-v1.rst
with
10 additions
and
6 deletions
docs/source/algorithms/TOFTOFMergeRuns-v1.rst
+
10
−
6
View file @
699e1011
...
@@ -55,8 +55,9 @@ Usage
...
@@ -55,8 +55,9 @@ Usage
ws2 = LoadMLZ(Filename='TOFTOFTestdata.nxs')
ws2 = LoadMLZ(Filename='TOFTOFTestdata.nxs')
# change sample logs for a second workspace, not needed for real workspaces
# change sample logs for a second workspace, not needed for real workspaces
AddSampleLog(ws1, 'temperature', str(294.14), 'Number')
lognames = 'temperature,run_start,run_end,monitor_counts,run_number'
lognames = 'temperature,run_start,run_end,monitor_counts,run_number'
logvalues = '296.1
5
,2013-07-28T11:32:19+0053,2013-07-28T12:32:19+0053,145145,TOFTOFTestdata2'
logvalues = '296.1
6
,2013-07-28T11:32:19+0053,2013-07-28T12:32:19+0053,145145,TOFTOFTestdata2'
AddSampleLogMultiple(ws2, lognames, logvalues)
AddSampleLogMultiple(ws2, lognames, logvalues)
# Input = list of workspaces
# Input = list of workspaces
...
@@ -97,9 +98,10 @@ Output:
...
@@ -97,9 +98,10 @@ Output:
.. testoutput:: ExTOFTOFMergeRuns2ws
.. testoutput:: ExTOFTOFMergeRuns2ws
Temperature of experiment for 1st workspace (in K): 294.149414
Property temperature does not match! TOFTOFTestdata: 294.14, but TOFTOFTestdata2: 296.16
Temperature of experiment for 2nd workspace (in K): 296.15
Temperature of experiment for 1st workspace (in K): 294.14
Temperature of experiment for merged workspaces = average over workspaces (in K): 295.149707
Temperature of experiment for 2nd workspace (in K): 296.16
Temperature of experiment for merged workspaces = average over workspaces (in K): 295.15
Duration of experiment for 1st workspace (in s): 3601
Duration of experiment for 1st workspace (in s): 3601
Duration of experiment for 2nd workspace (in s): 3601
Duration of experiment for 2nd workspace (in s): 3601
Duration of experiment for merged workspaces = sum of all durations (in s): 7202
Duration of experiment for merged workspaces = sum of all durations (in s): 7202
...
@@ -114,7 +116,7 @@ Output:
...
@@ -114,7 +116,7 @@ Output:
Run number for merged workspaces = list of all workspaces: ['TOFTOFTestdata', 'TOFTOFTestdata2']
Run number for merged workspaces = list of all workspaces: ['TOFTOFTestdata', 'TOFTOFTestdata2']
Monitor counts for 1st workspace: 136935
Monitor counts for 1st workspace: 136935
Monitor counts for 2nd workspace: 145145
Monitor counts for 2nd workspace: 145145
Monitor counts for merged workspaces = sum over all workspaces: 282080
Monitor counts for merged workspaces = sum over all workspaces: 282080
**Example - Merge group of workspaces**
**Example - Merge group of workspaces**
...
@@ -124,8 +126,9 @@ Output:
...
@@ -124,8 +126,9 @@ Output:
ws2 = LoadMLZ(Filename='TOFTOFTestdata.nxs')
ws2 = LoadMLZ(Filename='TOFTOFTestdata.nxs')
# change sample logs for a second workspace, not needed for real workspaces
# change sample logs for a second workspace, not needed for real workspaces
AddSampleLog(ws1, 'temperature', str(294.14), 'Number')
lognames = 'temperature,run_start,run_end,monitor_counts,run_number'
lognames = 'temperature,run_start,run_end,monitor_counts,run_number'
logvalues = '296.1
5
,2013-07-28T11:32:19+0053,2013-07-28T12:32:19+0053,145145,TOFTOFTestdata2'
logvalues = '296.1
6
,2013-07-28T11:32:19+0053,2013-07-28T12:32:19+0053,145145,TOFTOFTestdata2'
AddSampleLogMultiple(ws2, lognames, logvalues)
AddSampleLogMultiple(ws2, lognames, logvalues)
group=GroupWorkspaces('ws1,ws2')
group=GroupWorkspaces('ws1,ws2')
...
@@ -138,6 +141,7 @@ Output:
...
@@ -138,6 +141,7 @@ Output:
.. testoutput:: ExTOFTOFMergeRunsGroup
.. testoutput:: ExTOFTOFMergeRunsGroup
Property temperature does not match! TOFTOFTestdata: 294.14, but TOFTOFTestdata2: 296.16
Monitor counts for 1st workspace: 136935
Monitor counts for 1st workspace: 136935
Monitor counts for 2nd workspace: 145145
Monitor counts for 2nd workspace: 145145
Monitor counts for merged workspaces = sum over all workspaces: 282080
Monitor counts for merged workspaces = sum over all workspaces: 282080
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment