text_plain_output_1.png image_output_1.png
import numpy as np # linear algebra

import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

train_identity_data = pd.read_csv('../input/train_identity.csv')
train_transaction_data = pd.read_csv('../input/train_transaction.csv')
test_identity_data = pd.read_csv('../input/test_identity.csv')
test_transaction_data = pd.read_csv('../input/test_transaction.csv')

normalDataTransaction = train_transaction_data.loc[train_transaction_data['isFraud'] == 0]

fraudDataTransaction = train_transaction_data.loc[train_transaction_data['isFraud'] == 1]

raw_train_data = pd.merge(train_transaction_data, train_identity_data, on='TransactionID', how='left')

print(raw_train_data.head(5))