Score using MAS
Parameters:
Name | Type | Description |
---|---|---|
restaf |
store
|
store |
modelName |
string
|
name of model to be executed |
scenario |
object
|
can be [{name: var1, value: value1},{...} ] or {varname: value,...} |
- returns scoring results
promise
Example
async function example (store, model) {
let scenario = {
prescriber_count : 1,
strength_per_unit: 15,
age : 74,
avg_opioid_prescriber_rate: 10.4,
doctorshop_med : 1,
max_avg_med_90 : 10,
max_mme_per_day: 40,
max_opioid_prescriber_rate: 13.21,
opioid_days: 3
};
let result = await restaflib.masScore (store, model, scenario);
print.object(result, 'scoring result');
}