-- | In general, it is not easy to define the whole confusion matrix
-- generically without knowing anything about the source data. For certain
-- elements however, it is possible. These instances are all defined on
-- newtypes in order to not create instances on generic data types like lists.
module Statistics.ConfusionMatrix.Instances where
import Statistics.ConfusionMatrix
-- | The ctor expects the total number of possibilities first, then a list of
-- true positive elements, followed by a list of predicted elements.
newtype (Eq a, Ord a) => ListSimilar a = ListSimilar (Int,[a],[a])
instance (Eq a, Ord a) => MkConfusionMatrix (ListSimilar a) where
mkConfusionMatrix (ListSimilar (count,tp,pred)) = ConfusionMatrix
{ fn = error "fn undefined"
, fp = error "fp undefined"
, tn = error "tn undefined"
, tp = error "tp undefined"
}