This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Set MKL threads if Revolution R Open or Revoltion R Enterprise is available | |
if(require(Revobase)){ | |
setMKLthreads(4) | |
} | |
# Initialization | |
set.seed (1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(deployrUtils) | |
deployrPackage("rpart") | |
# load the model | |
if (!exists("model")) load(file="model.rData") | |
# provide some values for an observation to be scored | |
deployrInput('{"name": "balance","render": "numeric","default": 2000}') | |
deployrInput('{"name": "numTrans","render": "numeric","default": 10}') | |
deployrInput('{"name": "creditLine","render": "numeric","default": 18}') |