Metadata-Version: 2.1
Name: capexplain
Version: 0.3
Summary: Cape - a system for explaining outliers in aggregation results through counterbalancing.
Home-page: https://github.com/iitdbgroup/cape
Author: US <e@g.com>
Author-email: who@gmail.com
License: Apache2
Keywords: db
Platform: any
Classifier: Programming Language :: Python
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: End Users/Desktop
Classifier: Intended Audience :: Developers
Classifier: Topic :: Scientific/Engineering :: Information Analysis
Description-Content-Type: text/markdown
Requires-Dist: certifi (>=2018.4.16)
Requires-Dist: chardet (>=3.0.4)
Requires-Dist: colorful (>=0.4.1)
Requires-Dist: geopy
Requires-Dist: idna (>=2.7)
Requires-Dist: matplotlib (==3.0.2)
Requires-Dist: numpy (>=1.14.5)
Requires-Dist: pandas (==0.23.4)
Requires-Dist: patsy (>=0.5.0)
Requires-Dist: pkginfo (>=1.4.2)
Requires-Dist: psycopg2-binary (>=2.7.6)
Requires-Dist: python-dateutil (>=2.7.3)
Requires-Dist: pytz (>=2018.5)
Requires-Dist: requests (>=2.19.1)
Requires-Dist: requests-toolbelt (>=0.8.0)
Requires-Dist: scikit-learn (>=0.19.2)
Requires-Dist: scipy (==1.2.1)
Requires-Dist: six (>=1.11.0)
Requires-Dist: sklearn (>=0.0)
Requires-Dist: SQLAlchemy (==1.2.10)
Requires-Dist: statsmodels (>=0.9.0)
Requires-Dist: tqdm (>=4.23.4)
Requires-Dist: urllib3 (<1.24,>=1.23)
Requires-Dist: pandastable

# Cape

**Cape** () is a system for explaining outliers (surprisingly low or high) aggregation function results for group-by queries in SQL. The user provides the system with a query and a surprising outcome for this query. Cape uses patterns discovered the describe trends that hold in the data in aggregation to explain such outliers.

# Installation

Cape requires python 3. Install with pip:

~~~shell
pip install capexplain
~~~

Install from github

~~~shell
git clone git@github.com:IITDBGroup/cape.git capexplain
cd capexplain
python3 setup.py install
~~~

# Usage

Cape provides a single binary `capexplain` that support multiple subcommands. The general form is:

~~~shell
capexplain COMMAND [OPTIONS]
~~~

Options are specific to each subcommand. Use `capexplain help` to see a list of supported commands and `capexplain help COMMAND` get more detailed help for a subcommand.

## Overview

Cape currently only supports PostgreSQL as a backend database. To use Cape to explain an aggregation outlier, you first have to let cape find patterns for the table over which are you are aggregating. This an offline step that only has to be executed once for each table (unless you want to rerun pattern mining with different parameter settings).

## Mining Patterns

Use `capexplain mine [OPTIONS]` to mine patterns. Cape will store the discovered patterns in the database.

## Explaining Outliers

To explain an aggregation outlier use `capexplain explain [OPTIONS]`.


# Links

Cape is developed by researchers at Illinois Institute of Technology and Duke University. For more information and publications see the Cape project page [http://www.cs.iit.edu/~dbgroup/projects/cape.html](http://www.cs.iit.edu/~dbgroup/projects/cape.html).


