Publish0x: ETH Tipping Data Visualization (80/20) by tomoyan

View this thread on steempeak.com
· @tomoyan ·
$7.21
Publish0x: ETH Tipping Data Visualization (80/20)
![5qqp4nvdspnczft4mppogpg2rsqyymiuyrvaxhndtcdaa4nnfnwlebvw8ibxzusfeanibmqdrwbntconjbqvrhswy2dduuicndv2tspze3pykstdnvmwgos1kshp8svvmcukvdhyfb9h285zkfzy5fzmh5qxzi7yusd9ciyzf5qst3w1bhnncl8qrqao25zznorzxqfst9thq9vgvt_1_.jpg](https://images.ecency.com/DQmVEfYpfVj6Bj69pysvfoFxQ2CJ886ERPVVsnbHGzujLDy/5qqp4nvdspnczft4mppogpg2rsqyymiuyrvaxhndtcdaa4nnfnwlebvw8ibxzusfeanibmqdrwbntconjbqvrhswy2dduuicndv2tspze3pykstdnvmwgos1kshp8svvmcukvdhyfb9h285zkfzy5fzmh5qxzi7yusd9ciyzf5qst3w1bhnncl8qrqao25zznorzxqfst9thq9vgvt_1_.jpg)

On [publish0x](https://www.publish0x.com/tomoyan/furucombo-defi-value-menu-make-it-a-combo-xvrnnqr?a=4zbqpvkapr) platform, you can change tipping % and this is the last visualization, 80% author and 20% me.
Publish0x is a **Free ETH** tipping blogging platform and I was hoping to find some interesting tipping strategy for doing this visualization.
[![popup.png](https://images.ecency.com/DQmUeB73iZ1i9y8589kY2qxEmV1rpDYMm7c4UBu65yTodid/popup.png)](https://www.publish0x.com/tomoyan/furucombo-defi-value-menu-make-it-a-combo-xvrnnqr?a=4zbqpvkapr)

* [20% to author / 80% to me (Result here)](https://hive.blog/python/@tomoyan/publish0x-eth-tipping-data-visualization-20-80)
* [50% to author / 50% to me (Result here)](https://hive.blog/python/@tomoyan/publish0x-eth-tipping-data-visualization-50-50)
* 80% to author / 20% to me (This post)

to see how **ETH** tipping value is going to be affected.(also **BAT** and **LRC** tokens)

80/20 is my default tipping % because I don't have to move the slider up and down. 
![1.png](https://images.ecency.com/DQmPdLLz4NpSsyNXreJPVvjvQK2hq9scidUz1LxSz1A2umJ/1.png)

It is just too much work me to slide this for each post I want to tip, and also I think if I like a post, author deserve get most of the tip. (and i want something for tipping 🀣)
But anyway, here is the data I collected for this post.
```
# 80/20
tipping_data = {
    '1': {
        'eth': [0.00003438, 0.00000871],
        'bat': [0.0139],
        'lrc': [0.0096, 0.0096, 0.0097, 0.0097]
    },
    '2': {
        'eth': [0.00001311, 0.00000655, 0.00000655, 0.00000648, 0.00000648],
        'bat': [0.0052],
        'lrc': [0.0297]
    },
    '3': {
        'eth': [0.00002987, 0.00001493, 0.00000747],
        'bat': [0.0062, 0.0061],
        'lrc': [0.0076, 0.0076, 0.]
    },
    '4': {
        'eth': [0.00003259, 0.00000827, 0.00000827],
        'bat': [0.0065],
        'lrc': [0.0185, 0.0094, 0.0092]
    },
    '5': {
        'eth': [0.00003269],
        'bat': [0.0127, 0.0063],
        'lrc': [0.0089, 0.0089, 0.0095, 0.0095]
    },
    '6': {
        'eth': [0.00003415, 0.00001708, 0.00000854, 0.00000850, 0.00000850, 0.00000809],
        'bat': [0.0066],
        'lrc': []
    },
    '7': {
        'eth': [0.00001641, 0.00000821, 0.0000809],
        'bat': [0.0063, 0.0063],
        'lrc': [0.0318, 0.0079]
    },
}
```
Feed this data into my python plotly script. Looks like this πŸ‘‡
![2.png](https://images.ecency.com/DQmaNbSS1YZUxxzXSLpgusQUTG8N4mhdnoc3noiAjwACXrk/2.png)
You can also see the graph here.
https://floating-meadow-28045.herokuapp.com/chart-80-20
https://tomoyan.github.io/chart-80-20
Tipping earning avg is about ~$0.03 a day.

This was the week that **ETH** and all the other coins went down so if it were up, the daily avg could have been more than $0.03, but still an improvement from $0.02 a day πŸ˜‚ 4 months ago.

[Publish0x](https://www.publish0x.com?a=4zbqpvkapr) used to change payout coins depends on how you tip, how much you tip so that if you do 80/20, you would BAT more than other coins, or 20/80 you would get more LRC...etc and stuff.

But when [Publish0x](https://www.publish0x.com?a=4zbqpvkapr) implemented ETH tipping, I guess they change the payout so that you will get more **ETH** than any other coins regardless of how you tip.
Damn, there is no tipping hack or trick that I could find 🀣 

Maybe they will change this in the future... so I might try this again some time.
If you are interested in [Publish0x](https://www.publish0x.com?a=4zbqpvkapr) 
## Join here πŸ‘‡ You can use their payout to **Power Up** πŸ˜‰ 
<center>
<a href="https://www.publish0x.com?a=4zbqpvkapr"><img src="https://cdn.publish0x.com/prod/fs/images/de90d649817df3a1a67cec28b0db0e6baa607c9df0ee69e6e4306b807e96d30d.gif" width="336" height="280" /></a>
</center>

Here is the script for the chart.
```
from tip_data import tipping_data
import plotly.graph_objects as go
import requests
import statistics


def get_price(id):
    # Call coingecko API to get usd price
    base_url = 'https://api.coingecko.com/api/v3/simple/price'
    eth_url = '?ids=ethereum&vs_currencies=usd'
    bat_url = '?ids=basic-attention-token&vs_currencies=usd'
    lrc_url = '?ids=loopring&vs_currencies=usd'

    if id == 'ethereum':
        try:
            r = requests.get(base_url + eth_url, timeout=3)
            r.raise_for_status()
        except Exception as err:
            print("Exception Error:", err)
            return 0.0
    elif id == 'basic-attention-token':
        try:
            r = requests.get(base_url + bat_url, timeout=3)
            r.raise_for_status()
        except Exception as err:
            print("Exception Error:", err)
            return 0.0
    elif id == 'loopring':
        try:
            r = requests.get(base_url + lrc_url, timeout=3)
            r.raise_for_status()
        except Exception as err:
            print("Exception Error:", err)
            return 0.0
    else:
        return 0.0

    return r.json()[id]['usd']


def main():
    eth_price = get_price('ethereum')
    bat_price = get_price('basic-attention-token')
    lrc_price = get_price('loopring')

    eth_amount = 0.0
    bat_amout = 0.0
    lrc_amount = 0.0
    days = []
    eth_data = []
    bat_data = []
    lrc_data = []
    total_data = []

    for key in tipping_data:
        eth_amount = f"{sum(tipping_data[key]['eth']) * eth_price:.3f}"
        bat_amout = f"{sum(tipping_data[key]['bat']) * bat_price:.3f}"
        lrc_amount = f"{sum(tipping_data[key]['lrc']) * lrc_price:.3f}"

        days.append('Data ' + key)
        eth_data.append(eth_amount)
        bat_data.append(bat_amout)
        lrc_data.append(lrc_amount)
        tip_total = float(eth_amount) + float(bat_amout) + float(lrc_amount)
        total_data.append(tip_total)

    avg_total = f"${statistics.mean(total_data):.3f}"
    print(avg_total)

    eth_data = list(map(float, eth_data))
    avg_eth = f"${statistics.mean(eth_data):.3f}"
    print('AVG_ETH: ' + avg_eth)

    bat_data = list(map(float, bat_data))
    avg_bat = f"${statistics.mean(bat_data):.3f}"
    print('AVG_BAT: ' + avg_bat)

    lrc_data = list(map(float, lrc_data))
    avg_lrc = f"${statistics.mean(lrc_data):.3f}"
    print('AVG_LRC: ' + avg_lrc)

    # Daily tipping bar chart
    fig = go.Figure(data=[
        go.Bar(name='BAT', x=days, y=bat_data),
        go.Bar(name='ETH', x=days, y=eth_data),
        go.Bar(name='LRC', x=days, y=lrc_data)],
        layout_title_text=f"""
        Publish0x Tip 50% Author 50% Me Earning Avg: {avg_total}
        """
    )
    fig.update_traces(texttemplate='%{y:.3f}', textposition='outside')

    fig.add_trace(
        go.Scatter(
            name='Tip Total',
            x=days,
            y=total_data
        )
    )

    # Change the bar mode
    fig.update_layout(
        # barmode='stack',
        xaxis_title="Tip Data",
        yaxis_title="$ Amount",
        legend_title="Crypto Tips",
    )
    # fig.write_html('chart-20-80.html', auto_open=True)
    fig.write_html('chart-50-50.html', auto_open=True)
    fig.show()


if __name__ == '__main__':
    main()
```
<center>
    [Get Rewarded For Browsing! Are you Brave?](https://brave.com/tom490)
    [<img src="https://img.esteem.app/be00j8.png">](https://brave.com/tom490)
    [![happy tears](https://images.ecency.com/DQmUfaVp5UQvASdTyyLrNiBdGB7NxQfxE2wBpNivcDUkCfe/h.gif)](https://tomoyan.github.io/)
    ➑️ [Website](tomoyan.github.io)
    ➑️ [Twitter ](twitter.com/tomoyanTweet)
</center>
πŸ‘  , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
properties (23)
post_id87,523,609
authortomoyan
permlinkpublish0x-eth-tipping-data-visualization-80-20
categorycodeonsteem
json_metadata{"tags":["codeonsteem","python","plotly","data","publish0x","mini","marlians","dblog"],"image":["https:\/\/images.ecency.com\/DQmVEfYpfVj6Bj69pysvfoFxQ2CJ886ERPVVsnbHGzujLDy\/5qqp4nvdspnczft4mppogpg2rsqyymiuyrvaxhndtcdaa4nnfnwlebvw8ibxzusfeanibmqdrwbntconjbqvrhswy2dduuicndv2tspze3pykstdnvmwgos1kshp8svvmcukvdhyfb9h285zkfzy5fzmh5qxzi7yusd9ciyzf5qst3w1bhnncl8qrqao25zznorzxqfst9thq9vgvt_1_.jpg","https:\/\/images.ecency.com\/DQmUeB73iZ1i9y8589kY2qxEmV1rpDYMm7c4UBu65yTodid\/popup.png","https:\/\/images.ecency.com\/DQmPdLLz4NpSsyNXreJPVvjvQK2hq9scidUz1LxSz1A2umJ\/1.png","https:\/\/images.ecency.com\/DQmaNbSS1YZUxxzXSLpgusQUTG8N4mhdnoc3noiAjwACXrk\/2.png","https:\/\/cdn.publish0x.com\/prod\/fs\/images\/de90d649817df3a1a67cec28b0db0e6baa607c9df0ee69e6e4306b807e96d30d.gif","https:\/\/img.esteem.app\/be00j8.png","https:\/\/images.ecency.com\/DQmUfaVp5UQvASdTyyLrNiBdGB7NxQfxE2wBpNivcDUkCfe\/h.gif"],"links":["https:\/\/www.publish0x.com\/tomoyan\/furucombo-defi-value-menu-make-it-a-combo-xvrnnqr?a=4zbqpvkapr","https:\/\/hive.blog\/python\/@tomoyan\/publish0x-eth-tipping-data-visualization-20-80","https:\/\/hive.blog\/python\/@tomoyan\/publish0x-eth-tipping-data-visualization-50-50","https:\/\/floating-meadow-28045.herokuapp.com\/chart-80-20","https:\/\/tomoyan.github.io\/chart-80-20","https:\/\/www.publish0x.com?a=4zbqpvkapr","https:\/\/brave.com\/tom490","https:\/\/tomoyan.github.io\/","tomoyan.github.io","twitter.com\/tomoyanTweet"],"app":"steemit\/0.2","format":"markdown"}
created2020-09-15 14:37:45
last_update2020-09-15 14:37:45
depth0
children9
net_rshares17,650,211,378,847
last_payout2020-09-22 14:37:45
cashout_time1969-12-31 23:59:59
total_payout_value3.716 SBD
curator_payout_value3.494 SBD
pending_payout_value0.000 SBD
promoted0.000 SBD
body_length8,000
author_reputation870,963,589,956,079
root_title"Publish0x: ETH Tipping Data Visualization (80/20)"
beneficiaries[]
max_accepted_payout1,000,000.000 SBD
percent_steem_dollars10,000
author_curate_reward""
vote details (37)
@kamranrkploy ·
$0.09
It looks interesting. i am amazed that there are so many platforms coming out these days where one can earn while readingor / and  writing.
thanks for sharing the info 😊.
πŸ‘  
properties (23)
post_id87,525,919
authorkamranrkploy
permlinkqgpmwb
categorycodeonsteem
json_metadata{"app":"steemit\/0.2"}
created2020-09-15 17:21:51
last_update2020-09-15 17:21:51
depth1
children8
net_rshares352,919,575,000
last_payout2020-09-22 17:21:51
cashout_time1969-12-31 23:59:59
total_payout_value0.044 SBD
curator_payout_value0.045 SBD
pending_payout_value0.000 SBD
promoted0.000 SBD
body_length170
author_reputation21,877,616,239,495
root_title"Publish0x: ETH Tipping Data Visualization (80/20)"
beneficiaries[]
max_accepted_payout1,000,000.000 SBD
percent_steem_dollars10,000
author_curate_reward""
vote details (1)
@tomoyan ·
Yes, I like this platform because they payout in ETH and easy to tip and earn :)
properties (22)
post_id87,527,566
authortomoyan
permlinkqgpt9v
categorycodeonsteem
json_metadata{"app":"steemit\/0.2"}
created2020-09-15 19:39:33
last_update2020-09-15 19:39:33
depth2
children7
net_rshares0
last_payout2020-09-22 19:39:33
cashout_time1969-12-31 23:59:59
total_payout_value0.000 SBD
curator_payout_value0.000 SBD
pending_payout_value0.000 SBD
promoted0.000 SBD
body_length80
author_reputation870,963,589,956,079
root_title"Publish0x: ETH Tipping Data Visualization (80/20)"
beneficiaries[]
max_accepted_payout1,000,000.000 SBD
percent_steem_dollars10,000
@kamranrkploy · (edited)
$0.09
yes , i am joining this as well now so thanks for letting me know about the platform ☺️ @tomoyan.
πŸ‘  
properties (23)
post_id87,530,242
authorkamranrkploy
permlinkqgq5mu
categorycodeonsteem
json_metadata{"app":"steemit\/0.2","users":["tomoyan"]}
created2020-09-16 00:06:33
last_update2020-09-16 00:07:30
depth3
children6
net_rshares354,993,006,489
last_payout2020-09-23 00:06:33
cashout_time1969-12-31 23:59:59
total_payout_value0.044 SBD
curator_payout_value0.044 SBD
pending_payout_value0.000 SBD
promoted0.000 SBD
body_length97
author_reputation21,877,616,239,495
root_title"Publish0x: ETH Tipping Data Visualization (80/20)"
beneficiaries[]
max_accepted_payout1,000,000.000 SBD
percent_steem_dollars10,000
author_curate_reward""
vote details (1)