-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
It would be really nice to be able to use this library without first converting all probability vectors to 0 to 100 scale. Suggest adding a global option for this:
# Function to set the global option
set_probability_scale <- function(scale_0_1 = FALSE) {
options(use_prob_scale_0_1 = scale_0_1)
}Then modify each of the agg functions:
your_function <- function(prob_vector) {
if (getOption("use_prob_scale_0_1")) {
prob_vector <- prob_vector * 100
}
# ... rest of your function ...
}I think we'd also need to add an .onLoad function to set the option to FALSE by default (so this doesn't break XPT code).
Metadata
Metadata
Assignees
Labels
No labels