import pandas as pd
from ChannelAttributionPro import *
import urllib.request
Data = pd.read_csv("https://channelattribution.net/csv/Data.csv",sep=";")
password="yourpassword"
urllib.request.urlretrieve("https://channelattribution.net/csv/Data.csv", "Data.csv")
res=shapley(Data=Data, var_path="path", var_conv="total_conversions",
var_value="total_conversion_value",
var_null="total_null", cha_sep=">", password=password)
path_attribution=res["attribution"]
print(path_attribution)
res=shapley(Data=Data, var_path="path", var_conv="total_conversions",
var_value="total_conversion_value",
var_null="total_null", cha_sep=">", flg_simplified=False, password=password)
path_attribution=res["attribution"]
print(path_attribution)
res=shapley(Data=Data, var_path="path", var_conv="total_conversions",
var_value="total_conversion_value",
var_null="total_null", cha_sep=">", flg_write_nulls=1, password=password)
path_attribution=res["attribution"]
print(path_attribution)
res=shapley(Data=Data, var_path="path", var_conv="total_conversions",
var_value="total_conversion_value", var_null="total_null",
cha_sep=">", flg_write_paths=1, password=password)
path_attribution=res["attribution"]
print(path_attribution)
res=shapley(Data="Data.csv", var_path="path", var_conv="total_conversions",
var_value="total_conversion_value", var_null="total_null",
cha_sep=">", row_sep=";", file_output="ouput.csv", password=password)
print(res["attribution"])