Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ItemClicksAnalyser

Hierarchy

Index

Constructors

constructor

Properties

Protected database

database: Database

Database where to fetch data to analyse (and the revisions).

Methods

Protected computeAnalysis

Private computeFrequencies

  • Update an analysis by computing the global and local click frequencies, for each item with stats.

    This method must only be called once all item click logs have been processed.

    Parameters

    Returns void

Private createItemClickAnalysis

Private createItemGroupStats

Private createItemStats

getAnalysis

Protected makeAnalysisDeepCopy

Private processItemClickLog

  • Update an analysis by processing the given item click log. This includes updating both the related item and item group stats objects, which will be created if they do not exist yet.

    Parameters

    Returns void

Private updateItemGroupStatsWithClick

  • Update an item group stats object by processing the given item click log. If the related item group stats object does not exist yet, it is created.

    Parameters

    • log: TableEntry<ItemClickLog>

      The item click log to process.

    • analysis: ItemClicksAnalysis

      The analysis containing the item group stats to update.

    • clickIsLocal: boolean

      Whether the given item click log was recorded on the current page (true if it was).

    Returns void

Private updateItemStatsWithClick

  • Update an item stats object by processing the given item click log. If the related item stats object does not exist yet, it is created.

    Parameters

    • log: TableEntry<ItemClickLog>

      The item click log to process.

    • analysis: ItemClicksAnalysis

      The analysis containing the item stats to update.

    • clickIsLocal: boolean

      Whether the given item click log was recorded on the current page (true if it was).

    Returns void

Static splitItemGroupsByStatsAvailability

  • Split a list of groups into two sub-lists:

    • a sub-list with groups whose stats are available in the given analysis;
    • a sub-list with the other groups (with no stats).

    The order of the initial list is respected in each of the sub-lists.

    Parameters

    Returns ItemGroupsSplitByStatsAvailability

    An object with the two sub-lists of items.

Static splitItemsByStatsAvailability

  • Split a list of items into two sub-lists:

    • a sub-list with items whose stats are available in the given analysis;
    • a sub-list with the other items (with no stats).

    The order of the initial list is respected in each of the sub-lists.

    Parameters

    • items: Item[]

      The list of items to split.

    • analysis: ItemClicksAnalysis

      The analysis where to look for item stats.

    Returns ItemsSplitByStatsAvailability

    An object with the two sub-lists of items.

Generated using TypeDoc