Scripting in Batch Mode
In its simplest form, batch mode execution of IBM® SPSS® Modeler streams is performed one at a time using the command line arguments discussed in this guide. A given stream is executed without significantly altering its node parameters. While this may work well for automated production of monthly churn reports or predictions, it cannot handle the sophisticated processes that many advanced data miners would like to automate.
For example, a financial institution may want to construct a number of models using different data or modeling parameters, test the models on another set of data, and produce a report on the results. Because this process requires repetitive modifications to a stream and the creation and deletion of nodes, automating it requires the use of scripting. Scripting allows complex processes that would otherwise require user intervention to be automated and executed in batch mode.
To Execute a Script in Batch Mode
- Append the clemb command with the -script flag, specifying the name of the script that you want to execute.
- Also use the -execute flag with the above arguments to execute the specified script. This will run the stand-alone script in its entirety.
For example, to load and execute a script that runs a model producing churn scores that are stored as output for the data warehouse, you would use the following command:
clemb -server -hostname myserver -port 80
-username dminer -password 1234
-script clemscript.txt -execute