2081 10

CSC420 ยท 2081 ยท 5 marks

List any two OLAP operations with example. How do you compute rule coverage and rule accuracy?

List any two OLAP operations with example. How do you compute rule coverage and rule accuracy? [5]

Data Warehousing and Data MiningChapter 1: Introduction to Data WarehousingOLAP operation in multidimensional data model

Quick answer

Roll-up generates a summary from a lower level to a higher level. It can be performed by: - Reducing dimensions, or - Climbing up a concept hierarchy

OLAP Operations and Rule Coverage/Accuracy


Part 1: Two OLAP Operations with Examples

1. Roll-up (Consolidation / Aggregation)

Example: In the location dimension, data can be rolled up from city level to country level. For instance, sales data for cities like Kathmandu, Pokhara, and Biratnagar are aggregated (summed) to give total sales for Nepal as a country.

Concept hierarchy: Day โ†’ Week โ†’ Month โ†’ Year


2. Drill-down (Opposite of Roll-up)

Drill-down navigates from higher-level summarized data to lower-level detailed data. It is the reverse of roll-up, either by stepping down a concept hierarchy or by introducing additional dimensions.

Example: If we have quarterly sales data for a country, we can drill down to view monthly sales for each city within that country. This gives more granular, detailed information.


Part 2: Rule Coverage and Rule Accuracy

The quality of an association/classification rule R is measured by two factors: coverage and accuracy.

Let the rule be of the form:

R: A => B (If condition A, then class/consequence B)

Let:

  • n = total number of tuples in the dataset
  • nA = number of tuples satisfying condition A (antecedent)
  • nA,B = number of tuples satisfying both A and B

Rule Coverage

Coverage measures how often the rule applies to the dataset. It is the fraction of tuples that satisfy the antecedent of the rule.

$$\text{Coverage}(R) = \frac{n_A}{n}$$

Example: If a dataset has 1000 tuples and 400 tuples satisfy condition A, then:

$$\text{Coverage}(R) = \frac{400}{1000} = 0.4 = 40%$$


Rule Accuracy (Confidence)

Accuracy measures how often the rule is correct. It is the fraction of tuples satisfying the antecedent that also satisfy the consequent.

$$\text{Accuracy}(R) = \frac{n_{A,B}}{n_A}$$

Example: Out of the 400 tuples satisfying condition A, suppose 300 also satisfy B, then:

$$\text{Accuracy}(R) = \frac{300}{400} = 0.75 = 75%$$


Summary Table

MeasureFormulaMeaning
Coverage$n_A / n$How often the rule's condition applies
Accuracy$n_{A,B} / n_A$How often the rule is correct when it applies

A good rule should have both high coverage (applies to many tuples) and high accuracy (is correct most of the time).

Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.