crapher / pyhomebroker

Apache License 2.0
101 stars 42 forks source link

feat(orders): Added total amount to the order df #22

Closed lisandro closed 2 years ago

lisandro commented 2 years ago

What does this PR do?

Where should the reviewer start?

Calc of the new column here

How should this be manually tested?

Having an order with partial operations with different prices the sum of each should be the resulting value of this new column.

Any background context you want to provide?

I saw that HB does not sum correctly the total of each operation where there were different prices from the order price, so.

Example:

What are the relevant tickets?

NA

Screenshots (if appropriate)

We can see that the data frame has the correct value for operated values

             symbol settlement operation_type  size    price  remaining_size            datetime     status  cancellable       total
order_number                                                                                                                        
XXXX        AY24       48hs           SELL   696  5224.00               0 2020-01-10 11:43:47  COMPLETED        False   36366.000

Questions

crapher commented 2 years ago

El nombre me parece bien, dos comentarios nomas.

lisandro commented 2 years ago

Gracias @crapher !! Ahí fue 🚀