# Path: data/features/feature_combinations.py
# def pair_equality(dataframe, column_1, column_2, new_feature_name):
# def get_pair_equality(row, column_1, column_2):


from data.features import feature_combinations
import pandas as pd
"""
Simple example script for how to use functions from feature_combinations.py to add
extra features.

@author Dennis Soemers
"""


def run_example():
    # filepath to load dataframe from
    # NOTE: currently using dataset which was not preprocessed yet here. This is because
    # we need the GeoCode feature for our example, which is removed by preprocess_data_raw.py
    DATA_FILEPATH = '../../real_data/anonymized_dataset.csv'

    # load dataframe
    df = pd.read_csv(DATA_FILEPATH)

    # add a binary feature to our dataset, which tells us whether or not the Country and GeoCode values of
    # a transaction are equal

# Path: data/features/feature_combinations.py
# def pair_equality(dataframe, column_1, column_2, new_feature_name):
# def get_pair_equality(row, column_1, column_2):


# Path: data/features/examples/feature_combinations_example.py
from data.features import feature_combinations
import pandas as pd

"""
Simple example script for how to use functions from feature_combinations.py to add
extra features.

@author Dennis Soemers
"""


def run_example():
    # filepath to load dataframe from
    # NOTE: currently using dataset which was not preprocessed yet here. This is because
    # we need the GeoCode feature for our example, which is removed by preprocess_data_raw.py
    DATA_FILEPATH = '../../real_data/anonymized_dataset.csv'

    # load dataframe
    df = pd.read_csv(DATA_FILEPATH)

    # add a binary feature to our dataset, which tells us whether or not the Country and GeoCode values of
    # a transaction are equal

    df = feature_combinations.pair_equality(df, "Country", "GeoCode", "Country_GeoCode_Eq")