CheckForSampleLogs v1

../_images/CheckForSampleLogs-v1_dlg.png

CheckForSampleLogs dialog.

Summary

Check if the workspace has some given sample logs

Properties

Name Direction Type Default Description
Workspace Input Workspace Mandatory The workspace to check.
LogNames Input string   Names of the logs to look for
Result Output string    

Description

Check if the workspace has some given sample logs. An empty string will be returned if all the logs are found, otherwise the result is an error message

Usage

Note

To run these usage examples please first download the usage data, and add these to your path. In MantidPlot this is done using Manage User Directories.

#load a workspace with logs
ws=Load("CNCS_7860")

sampleLogs="Phase1,Phase3"
result=CheckForSampleLogs(ws,sampleLogs)
if len(result)==0:
    print "We found logs for "+sampleLogs
sampleLogs="DJIA"
result=CheckForSampleLogs(ws,sampleLogs)
print result.strip()

Output:

We found logs for Phase1,Phase3
Property DJIA not found

Categories: Algorithms | PythonAlgorithms | Utility | Workspaces