A heuristic used to calculate the significance of a term in a subset

interface SignificanceHeuristic {
    name: string;
    score(
        subsetFreq: number,
        subsetSize: number,
        supersetFreq: number,
        supersetSize: number,
    ): number;
}

Properties

Methods

Properties

name: string

Methods

  • Calculates the significance of a term found in a subset sample

    Parameters

    • subsetFreq: number

      The frequency of the term in the selected sample

    • subsetSize: number

      The size of the selected sample (typically number of docs)

    • supersetFreq: number

      The frequency of the term in the superset from which the sample was taken

    • supersetSize: number

      The size of the superset from which the sample was taken (typically number of docs)

    Returns number

    a "significance" score