Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(exchanges): use dictionary to represent order book #4

Open
daoio opened this issue Oct 28, 2024 · 0 comments
Open

feat(exchanges): use dictionary to represent order book #4

daoio opened this issue Oct 28, 2024 · 0 comments
Assignees
Labels
exchanges: update 📈 Any update to the code of existing exchanges good first issue 😇 Good for newcomers

Comments

@daoio
Copy link
Collaborator

daoio commented Oct 28, 2024

Describe the solution you'd like
Instead of representing the book as List[List[List[float]]]:

[ 
  [[p0,q0],...,[pn, qn]]  # asks
  [[p0,q0],...,[pn,qn]]   # bids
]

Represent it as dictionary:

{
  "asks": [(p0,q0),...,(pn,qn)],
  "bids": [(p0,q0),...,(pn,qn)]
}
@daoio daoio added good first issue 😇 Good for newcomers exchanges: update 📈 Any update to the code of existing exchanges labels Oct 28, 2024
@daoio daoio self-assigned this Oct 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
exchanges: update 📈 Any update to the code of existing exchanges good first issue 😇 Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant