Classification Metrics

Classification Metrics API Reference

Functions

ColdToHot(Y, Schema::ClassificationLabel)

Turns a cold encoded Y vector into a one hot encoded array.

source
HighestVote(yhat)

Returns the column index for each row that has the highest value in one hot encoded yhat. Returns a one cold encoded vector.

source
HighestVoteOneHot(yhat)

Turns the highest column-wise value to a 1 and the others to zeros per row in a one hot encoded yhat. Returns a one cold encoded vector.

source
HotToCold(Y, Schema::ClassificationLabel)

Turns a one hot encoded Y array into a cold encoded vector.

source
IsColdEncoded(Y)

Returns a boolean true if the array Y is cold encoded, and false if not.

source

" LabelEncoding(HotOrCold)

Determines if an Array, Y, is one hot encoded, or cold encoded by it's dimensions. Returns a ClassificationLabel object/schema to convert between the formats.

source
MulticlassStats(Y, GT, schema; Microaverage = true)

Calculates many essential classification statistics based on predicted values Y, and ground truth values GT, using the encoding schema. Returns a dictionary of many statistics...

source
MulticlassThreshold(yhat; level = 0.5)

Effectively does the same thing as Threshold() but per-row across columns.

Warning this function can allow for no class assignments. HighestVote is preferred

source
Threshold(yhat; level = 0.5)

For a binary vector yhat this decides if the label is a 0 or a 1 based on it's value relative to a threshold level.

source