question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Adding "total price" worth to ladder whale orders

See original GitHub issue

Now with #66 merged, hovering over a bubble shows the total price of the order/s. I tried to add the same to the ladder whale orders, and if I play with a simple test dataframe it works, but when I try with app.py, I get an error on:

    vol_grp_bid = vol_grp_bid[
        ((vol_grp_bid[TBL_VOLUME] >= minVolume) & (vol_grp_bid['count'] >= 2.0) & (vol_grp_bid['count'] < 70.0))]

for some reason. Could someone with more experience implement this?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
mifunetoshirocommented, Feb 25, 2018

Yes, but in the way that I did it:

    vol_grp_bid = bid_tbl.groupby([TBL_VOLUME]).agg({TBL_PRICE: [np.min, np.max, 'count'], TBL_VOLUME: np.sum, 'total_price': np.sum})
    vol_grp_bid.columns = ['min_Price', 'max_Price', 'count', 'volume', 'total_price']
    vol_grp_ask = ask_tbl.groupby([TBL_VOLUME]).agg({TBL_PRICE: [np.min, np.max, 'count'], TBL_VOLUME: np.sum, 'total_price': np.sum})
    vol_grp_ask.columns = ['min_Price', 'max_Price', 'count', 'volume', 'total_price']

It’s not needed, because there aren’t 2 levels, and you get an error:

AttributeError: ‘Index’ object has no attribute ‘droplevel’

0reactions
theimo1221commented, Feb 25, 2018

ah okay, gotcha.

Read more comments on GitHub >

github_iconTop Results From Across the Web

DRIP Whale Status Changes Ladder Strategy - Ryan - Medium
Most of the past “hot” platform's native tokens aren't even worth 1 cent! DRIP's price dropped because of a multitude of reasons —...
Read more >
pmaji/crypto-whale-watching-app: Python Dash app ... - GitHub
Ladder Price -Point Whales: Place many medium-sized orders for identical volume increasing in price; Example: 500 total ETH for sale starting at $900...
Read more >
Understanding Price Ladder Orders Trading - HyperTrader
So, instead of putting a single buying order for a given price ($34k), you can leverage price ladder trading to put in four...
Read more >
Unusual Options Flow Tutorial | OptionStrat
The color of stock symbol and premium (which is the total amount spent on or ... are often broken up into smaller orders...
Read more >
3x7sshd43 - Python - OneCompiler
... actress actual adapt add addict address adjust admit adult advance advice ... alter always amateur amazing among amount amused analyst anchor ancient ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found