Outlier detection in contingency tables based on minimal patterns