Apriori

Apriori files can be used to control how TauArgus suppresses cells. These files can mark individual cells as protected, safe, or modify the suppression cost.

Use an existing file

import piargus as pa

apriori = pa.Apriori.from_hst("apriori.hst")

Create an apriori file programmatically

import piargus as pa

apriori = pa.Apriori(expand_trivial=True)
apriori.change_status(['A', 'ExampleDam'], pa.SAFE)
apriori.change_status(['A', 'ExampleCity'], pa.SAFE)
apriori.change_cost(['C', 'ExampleDam'], 10)
apriori.change_protection_level(['C', 'ExampleCity'], 5)

apriori.to_hist("apriori.hst")

Attaching apriori to a table

Simply pass it as a parameter when creating a Table or TableData instance:

table = pa.Table(['symbol', 'regio'], 'income', ...,
                 apriori=apriori)