SetPredictionThreshold | R Documentation |
The prediction threshold is used by a binary classification model when deciding between the positive and negative class.
SetPredictionThreshold(model, threshold)
model |
An S3 object of class dataRobotModel like that returned by the function GetModel, or each element of the list returned by the function ListModels. |
threshold |
numeric. The threshold to use when deciding between the positive and negative class. Should be between 0 and 1 inclusive. |
Note: This feature can only can be used when PredictionThresholdReadOnly
is FALSE
.
Models typically cannot have their prediction threshold modified if they have been used to
set a deployment or predictions have been made with the dedicated prediction API.
Returns NULL but updates the model in place.
## Not run:
projectId <- "59a5af20c80891534e3c2bde"
modelId <- "5996f820af07fc605e81ead4"
model <- GetModel(projectId, modelId)
SetPredictionThreshold(model, threshold = 0.6)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.