View source: R/metrics-ordinal.R
assert_input_ordinal | R Documentation |
Function assesses whether the inputs correspond to the requirements for scoring ordinal forecasts.
assert_input_ordinal(observed, predicted, predicted_label)
observed |
Input to be checked. Should be an ordered factor of length n with N levels holding the observed values. n is the number of observations and N is the number of possible outcomes the observed values can assume. |
predicted |
Input to be checked. Should be nxN matrix of predicted
probabilities, n (number of rows) being the number of data points and N
(number of columns) the number of possible outcomes the observed values
can assume.
If |
predicted_label |
Ordered factor of length N with N levels, where N is the number of possible outcomes the observed values can assume. |
Returns NULL invisibly if the assertion was successful and throws an error otherwise.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.