what python package, or algorithm can be used to find a pattern like "buy A, then not buy B", like the opposite of association rule?

we know association rule mining can find the patterns like bread -- milk. It means if you buy bread, then you might buy milk with high probability.

But, is there a python package, or algorithm which can find patterns like buy coke, then not buy pepsi? So it means if you buy A, then you might not buy B with probability?

Topic association-rules python

Category Data Science

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.