Implementation of the Heuristic Methods MAX, AND, OR (Obozinski et al., Genome Biology, 2008,
doi:10.1186/gb-2008-9-s1-s6).
Usage
heuristic.max(S, g, root = "00")
heuristic.and(S, g, root = "00")
heuristic.or(S, g, root = "00")
Arguments
S
a named flat scores matrix with examples on rows and classes on columns.
g
a graph of class graphNEL. It represents the hierarchy of the classes.
root
name of the class that it is the top-level (root) of the hierarchy (def:00).
Value
a matrix with the scores of the classes corrected according to the chosen heuristic algorithm.
Details
Heuristic Methods:
MAX: reports the largest logist regression (LR) value of self and all descendants: \(p_i = max_{j \in descendants(i)} \hat{p_j}\);
AND: reports the product of LR values of all ancestors and self. This is equivalent to computing the probability that all
ancestral terms are "on" assuming that, conditional on the data, all predictions are independent: \(p_i = \prod_{j \in ancestors(i)} \hat{p_j}\);
OR: computes the probability that at least one of the descendant terms is "on" assuming again that, conditional on the data,
all predictions are independent: \(1 - p_i = \prod_{j \in descendants(i)} (1 - \hat{p_j})\);