/perspective-order-book

Visualize an order book using Perspective and the Gemini sandbox API.

Primary LanguagePython

Visualizing Order Books with Perspective

GIF of ETHUSD Order Book Dashboard using Perspective

Using Perspective, we can create interactive visualizations on a streaming order book, analyzing and dissecting it as new orders come in and the state of the book changes to reflect the market.

We use Gemini for the order book data (using their Sandbox), and create a datasource in Python that feeds data into a perspective-python Tornado server. In the browser, we use @finos/perspective-workspace to create a dynamic, user-configurable dashboard that allows us to analyse, visualize, and transform the data in real-time.

Using a Client-server replicated Perspective configuration, our dashboard performs and scales well across multiple clients, all of whom are kept in sync with the server automatically.

Dependencies

Install the JS and Python dependencies:

yarn
python3 -m pip install perspective-python websocket-client

Build and Run

The server and client need to be run in separate processes:

yarn start

and in another terminal window:

yarn start:server