BookMap User Guide for NinjaTrader

100% found this document useful (2 votes)
387 views14 pages
BookMap is a trading application that provides a consolidated visualization of past and present market depth over time. It displays the evolving order book activity to help traders analyze m…

Uploaded by

Roseane Sobral
  • Introduction
  • Importing BookMap Live
  • BookMap Live
  • Placing Orders
  • Order Status
  • Approximation of Order Queue
  • Trades Visualization
  • BookMap Replay

______________________________________________________________________________

BookMap
User Guide

______________________________________________________________________________

Introduction
BookMap is an innovative analysis and trading application that delivers a consolidated
visualization of past and present market depth. Using a configurable color scheme, BookMap
keeps record of the order book activity over time and displays it to the trader together with
current market depth. The visualization of the evolving order book activity, enhancestraders
ability toanalyze market dynamics and patterns, as well as assessing the perpetual strength and
weakness of different price levels. BookMap allows traders to quickly translate market analysis
into trading actions with one click trading capability directly from the BookMap chart.

1. SystemRequirements
The following hardware and software specifications are the minimal requirements for
installing and using BookMap:
a)
b)
c)
d)
e)
f)

Windows 7, Vista, 2000 or XP.


Monitor with minimum resolution of 1024x768
Minimum of 3Gigabytes RAM and 40 Megabytes free disk space.
Intel Core 2 DUO (or equivalent), 2.0 GHz or above
Stable internet connection. Minimal speed 1Mb/Sec
A mouse with a middle button is required for one-click trading.

2. User manual
BookMaphas two modes of operation: BookMap live and BookMap replay (offline). The live
mode presents real-time market data transmitted by the users market depth data provider
through the NinjaTrader platform. It also allows thetransmission of orders to the
NinjaTrader platformusing one-click order placement directly from the BookMap [Link]
replay mode allows traders to replay recorded trading sessions and view the evolution of
the order book over the entire session. Traders can place and execute simulated orders to
verify how theirtrading decisions and strategies fit theiranalysis of the market based on
BookMap insights. Unlike the live mode, BookMap Replay is independent of any trading
platform and runs as a standalone application

Page1of13

______________________________________________________________________________
Importing BookMap Live
Before running BookMap live for the first time, the BookMap script has to be imported as a
Strategy to the NinjaTrader platform.
To import the BookMap script to the following (please note, this process is only performed
during the first operation of BookMap)
a.) Open you NinjaTrader platform. Got to File -> Utilities -> Import NinjaScript. This should
open a file browser.
b.) From the file browser, go to the "BookMap for NinjaTrader" folder. By default, this will
be located under C:\Program Files (x86)\BookMap\BookMap for NinjaTrader\. Select
[Link] and click OK. This should start the import process and add
BookMap as an Indicator to NinjaTrader.
Note that BookMap for NinjaTrader includes also [Link]. This file should be used
by those who wish to import BookMapto NinjaTrader as a Strategy. The difference
between running BookMap as an Indicator or as a Strategy is that the latter provides
trading capabilities. However, due to the specific way NinjaTrader has implemented its
API, there are several important limitations to consider when using BookMap as a
Strategy. More on these limitations below under important notes about order handling
and order status.

Running BookMap Live after


To run BookMap live after importing the BookMap script, take the following steps:

a.) Open NinjaTrader Platform and connect to your market depth data provider from
the NinjaTrader platform. Please note that we recommend to start using BookMap
first with a live data feed, but with a paper trading account, before switching to a
live account.
b.) Click File -> New -> Chart. Choose any instrument for the chart. In order to reduce
loading time, set Period -> Type to Seconds and set Data -> Load Data as Bars.
Click [Link] note that you should only select a single instrument for the chart.
The chart only serves as a launching pad for BookMap. You will be able to add more
instruments on BookMap as described below.

Page2of13

______________________________________________________________________________
c.) Right click on the chart and choose Indicators (or Strategies if you imported
BookMap as a Strategy). From the list of available strategies double click on
BookMap. This will open an indicator configuration window.

BookMap Indicator Configuration Window

d.) If you are using BookMap as a Strategy, set General -> Enable to True.
e.) BookMap will open by default the instrument you chose for the NinjaTrader chart.
To display more instruments on BookMap simply add the comma separated
(without spaces) list of additional instruments to BookMap Symbols on the
strategy configuration window (e.g. ES 03-14,FDAX 03-14,NQ 03-14,CL 03-14,GC 0414). Please note the instruments syntax should be the same syntax used by
NinjaTrader. Use Tools -> Instrument Manager to find the NinjaTrader instrument
syntax. BookMap will only present instrument for which you have market depth
data. To make sure your data provider to supply depth data check the data provided
for your instruments of choice using File -> New -> Level II.

Page3of13

______________________________________________________________________________
f.) After you entered the list of BookMap Symbols, click OK. This will open the
BookMap control window with all your specified instruments. Click any of the
symbols buttons to open their respective BookMap charts.

BookMap Control Window

Additional configuration notes


a.) If you are running BookMap as a Strategy, you should pay attention to your
NinjaTrader Order Handling settings on the BookMap strategy configuration
window. Depending on your NinjaTrader configuration, once you close and/or
reopen BookMap, NinjaTrader may close pending orders and open positions that
you have entered using BookMap. To avoid this, set Exit on close under Order
Handling (on the strategy configuration window) to False.
b.) Please note that due to a NinjaTrader limitation, open orders and position you
already have on the platform before starting any BookMap session will not be
displayed on BookMap. BookMap will only present orders and position you have
entered into during your current BookMap session.
c.) Due to a NinjaTrader limitation, it is impossible to add more instruments after
BookMap has started. However, you can remove instruments by pressing X near the
corresponding instrument in the BookMap control window. If you want to add other
instruments, you will have to close BookMap and the chart on which BookMap runs
as a strategy and reopen BookMap as explained above with your new list of
instruments.

Page4of13

______________________________________________________________________________

BookMap Live
General Orientation:
BookMap Live has several distinctive elements:
a) The blue and green bars on the far right side represent the volume of executed orders at
each price level accumulated from the start of the session. The blue and green colors
represent the relative size of executed orders by each group of aggressors. Blue
represents buyers were the aggressors and green represents sellers were the
aggressors. This can help traders assess which aggressors have had more power at the
relevant price level since the start of the session.
The volume bars can be reset to restart accumulating executed orders. This can be done
either manually or automatically at a preset frequency. To reset the volume bars, place
the mouse cursor over the volume bars area and right click to choose from either a
manual reset or automatic reset settings.

Page5of13

______________________________________________________________________________
b) The green and blue bars to the left of the volume bars represent the size of the current
bid (blue) and ask (green) orders at each price level.
c) The green and blue lines on the left side of the chart represent the best bid and ask
prices.
d) The color shadesof the various price levels represent the evolution of the order book
during the session. BookMap keeps the history of the order book size at each price level
with a matching color code. The brighter the color the larger the order book size at that
price level. The color shade settings are configurable, as explained below.
When a price level goes out of the range transmitted by the exchange (for example,
CME transmits only the best 10 levels of bid and ask) BookMap keeps record of its last
transmitted size and updates it once the level returns to the transmitted range. This
allows traders to estimate market depth even beyond the exchange transmitted range.
e) The progressing yellow vertical line represents the current time. The area left of the
vertical line representshistorical price changes and order book size. The area to the right
of the yellow line is an extended picture of the current price and order book size.

BookMap Chart

Page6of13

______________________________________________________________________________

Placing Orders:
Note: the sections relating to order placement and order status are only relevant when
running BookMap as a Strategy. None of the features described in the next 2 section is
available when running BookMap as an Indicator.

Every time the BookMapchartopens the one-click trading feature is disabled. To enable one
click trading click the
icon above the chart for trading configurations. This will open a
new window. Check Enable One-Click Trading and specify the number of contracts per click
(order size). Once One-Click Trading is enabled follow the instruction below to place or
cancel orders:
a) To place a Buy Limitorder, click the left mouse button below the current bid at the
desired price level. Note that clicking the left mouse button at or above the current ask
will result in a buy limit at current market price.

b) To place a Sell Limitorder, click the right mouse button above the current ask at the
desired price level. Note that clicking the right mouse button at or below the current bid
will result in a sell limit at current market price.
c) A single mouse click places an order for the number of contracts specified by the trader
in the trading [Link] additional mouse click will add another order for a
similar number of contracts.
d) To cancel pending orders, place the mouse pointer over the relevant price level and click
the middle mouse button.
e) To delete all of the pending orders at a certain price level place the mouse pointer over
the relevant price level and press CTRL + click the middle mouse button.
f)

The cancel all pending orders function, normally accessible using the icon above the
chart, is disabled in BookMap for NinjaTrader due to the limitation of the NinjaTrader
API detailed below.

g) The cancel exit all open positions,normally accessible usingthe icon above the chart,
is disabled in BookMap for NinjaTrader, due to the limitation of the NinjaTrader API
detailed below.

Page7of13

______________________________________________________________________________
Order Status:
a) Cyan circle marks the placement of a buy order. Cyan line extends from the circle until
the order is either filled or cancelled. A filed buy order is marked by cyan square.
b) Magenta circle marks the placement of a sell order. Magenta line extends from the
circle until the order is either filled or cancelled. A filed buy order is marked by magenta
square.
c)

It is possible to define what type of order information will be displayed on the chart. By
default pending orders, cancelled orders, and executions are all presented on the chart.
To change the default settings, click the
the relevant information.

icon for trading configurations and uncheck

d) The pending orders and open positions are also designated by counters above the chart.
e) P&L is indicated above the chart. The P&L is asummation of both the realized and
unrealized P&L during the session.

Important notes about order handling and status:


a) Due to limitations and design of the NinjaTrader API BookMap can only display orders
and positions that were initiated using BookMap during the current session. BookMap
will not be able to display orders and positions initiated through the NinjaTrader
platform or orders and position that existed prior to the current BookMap session,
whether they were initiated through NinjaTrader or through BookMap
b) Due to NinjaTrader API structure, whenever a trader is using the close all
orders/positions from the NinjaTraderSuperdom, or flatten all function, BookMap will
be closed.
c) By NinjaTrader design there are limitations using BookMap as a Strategy while using
NinjaTraderChart Trader at the same time.

[See figure on the next page]

Page8of13

______________________________________________________________________________

BookMap Live with pending, cancelled and executed orders

Approximation of Order Queue:


BookMap can display an approximation of the position of the traders order in the queue of
all pending orders at the relevant price level. BookMap approximates the position in the
queue according to FIFO matching algorithm, using pessimisticassumptions relating to
cancelled orders. The ability to display a more accurate position in the queue ultimately
depends on the quality of data that is available for distribution on the trading platform.
BookMap presents queue approximation with white vertical lines on top of the current
order book histogram. The place in the queue is illustrated by the position of the line over
the bar representing the current size of pending order at any given price level.
In order to activate the presentation of queue approximation, click the
configurationand check Orders Queue.

icon for trading

Page9of13

______________________________________________________________________________
Trades Visualization:
BookMap can display a graphical representation of all trades (i.e. of all market participants)
that took place during the session for the displayed instrument. BookMapdrawsvarying sizes
of red or yellow circles over the best bid and ask line. The circles are drawn with precision of
a single pixel of your monitor. The area of the circle represents total executed volume. This
size is scaled to create circles of a reasonable range per each instruments volume. The
center of the circle represents the exact time and the volume weighted average price of all
trades that occurred at given pixel (if occurred). According to the location of the circles on
the price axis and the red-to-yellow color gradient used, users can identify whether the
traded volume was initiated by buyer(s) or by seller(s).The redder the color of the circle, the
greater the sellingactivityat that price and time. The yellower the color of the circles, the
greater the buying activity at that price and time.
To activate trades visualization, click the
Markets trades.

icon for trading configurationand check

Chart contrast and other Settings:


a) BookMap automatically sets the contrast of the chart heat map based on the maximum
size on the order book and the distribution of pending prders at the different price
levels.
Users can control when BookMap recalibrates the heat map contrast. It can be set at
predefined frequencies and at every time the chart is recentered. To control these
setting, click the contrast icon above the chart and check the recalibration options you
want to use.
User can also control the brightness of the display by using the slider on the contrast
settings window.

BookMapContrast Configuration

Page10of13

______________________________________________________________________________
b) For a zoomed in and out view of the chart click the

and

icons above the chart.

c) Use the
icon above the chart to scroll the chart sideways. Note that while thehand
icon is pressed BookMap will keep the presentation anchored to the area chosen by the
trader. While in scrolling mode the chart can be zoomed in and out while anchoring to
the middle point of the current chart view. Zooming in and out in scrolling mode can be
done either with the zoom in and out icons or with mouse scrolling. In order to switch
back to current time unclick the hand icon.

[Intentionally left blank]

Page11of13

______________________________________________________________________________
BookMap Replay
BookMap Replay enables to replay pre-recorded market data and place order in simulation
mode during the replayed session. Except for playing non-real time data, the chart in the
BookMap replay mode has the same features as in the live mode BookMap live

Running BookMap Replay:


a.) Open BookMap Replay by clicking your desktop shortcut. This will open BookMap
Replay control window.

c.) In the control windowclick Feed. This will open a new window. Choose one of the text
feed files and click Open. Each feed file represents a prerecorded trading sessions.

Page12of13

______________________________________________________________________________

d.) The recorded instruments will now load. They will initially be displayed as grayed out
buttons and will turn active once information is fully loaded.

e.) You are now ready to replay the recorded session. Click any of the recorded
instruments buttons to open the relevant BookMap Replay chart window. Note that
once the data of the recorded instruments isfully loaded the file start replaying
automatically even if the chart is not open. You can view the date and time progression
above the instruments symbols on the BookMap replay control window. Click any of
the active symbolsbuttons to open BookMap chart.
f.) To pause and for faster or slower replay speed, use the controllers above the BookMap
chart.

Page13of13

Common questions

Powered by AI

When using BookMap as a Strategy on NinjaTrader, traders should be aware of several limitations. One major limitation is that BookMap can only display orders and positions initiated during the current session; it cannot display orders and positions from NinjaTrader or from previous BookMap sessions . Another limitation involves the inability to add instruments once BookMap has started, necessitating users to close and reopen BookMap to add new symbols . Furthermore, due to NinjaTrader’s API structure, functionalities like 'flatten all positions' from the NinjaTrader SuperDOM cause BookMap to close . Traders should also be mindful that pending orders on BookMap might automatically be closed if certain NinjaTrader order handling settings are left unchanged . These limitations underscore the need for strategic planning and configuration before using BookMap as a Strategy.

The trades visualization feature in BookMap plays a crucial role in providing a graphical representation of all trades executed during a session for the displayed instrument. This feature presents trades as varying-sized red or yellow circles that appear over the best bid and ask lines . The area of each circle is proportional to the total executed volume, scaled for each instrument, while the center of a circle marks the exact time and volume-weighted average price of trades at given pixel locations. The color gradient from red to yellow indicates whether selling or buying activity predominates; redder circles denote greater selling activity, and yellower circles indicate predominant buying activity . To configure this feature, users can enable trades visualization by selecting 'Market’s trades' in the trading configuration settings . This visualization provides immediate insights into trade flows, aiding traders in evaluating market sentiment and activity.

When closing BookMap and NinjaTrader sessions with open orders or positions, traders might face challenges primarily due to API limitations. Specifically, NinjaTrader’s API does not display orders and positions that were initiated before the current session in BookMap; thus, closing BookMap may inadvertently leave the trader without full visibility over remaining open orders or positions . Additionally, using functionality like ‘flatten all’ through NinjaTrader’s SuperDOM can automatically close BookMap, which creates a risk of executing unintended market actions without prior confirmation . Furthermore, if the order handling settings are not appropriately managed, notably the "Exit on close" option, traders may find their pending orders prematurely closed upon exiting BookMap . These aspects underline the importance of understanding these system interactions and ensuring all data and trading configurations are fully settled prior to closing the session to avoid unintended exposures or market actions.

BookMap enhances a trader's ability to analyze market dynamics by providing a consolidated visualization of past and present market depth along with the evolution of the order book activity. The configurable color scheme allows traders to visualize which aggressors were more dominant at specific price levels over time . This visualization helps traders to assess the strength and weakness of different price levels by displaying the volume of executed orders (buyer vs. seller aggressors), which can indicate potential support and resistance levels. Additionally, the order book's history and color-coded representation of order sizes give traders insights into market trends and liquidity beyond the exchange-provided data . This enables traders to incorporate these insights into timely trading actions using the one-click trading capability in BookMap .

To set up BookMap as a live trading tool on the NinjaTrader platform, follow these steps: First, import the BookMap script as a Strategy into NinjaTrader through File -> Utilities -> Import NinjaScript, then select the appropriate BookMapIndicator.zip file . After importing, open NinjaTrader and connect to a market depth data provider . Create a new chart with an instrument, using 'Seconds' for the time setting and 'Bars' for loading data to expedite the process . Then, right-click on the chart to choose 'Indicators' or 'Strategies', depending on how BookMap was imported, and configure BookMap settings by enabling it as a Strategy if needed . Finally, add any additional instruments to BookMap by entering them into the 'BookMap Symbols' field in the Strategy configuration window . This process ensures BookMap is fully integrated and ready for live trading on NinjaTrader.

BookMap assists traders in estimating market depth beyond the exchange-transmitted range by retaining the history of the order book size at each price level along with the color-coded representation of the order book . When certain price levels go out of the range transmitted by the exchange, such as CME's 10 levels of bid and ask, BookMap keeps a record of the last transmitted size of these levels and updates them when they return to the transmitted range. This historical record allows traders to visualize potential changes in market depth for price levels not currently covered by the exchange data. The brightness of the color shades indicates larger order book sizes, providing an intuitive way to estimate market depth beyond what is currently visible in the market data feed . This capability allows traders to understand liquidity dynamics at deeper levels of the market.

Using FIFO (First-In, First-Out) queue approximations for pending orders in BookMap allows traders to gauge the likely position of their orders in the pending order queue at specific price levels. This approximation employs pessimistic assumptions about canceled orders, enabling traders to understand their order's potential execution priority compared to others . It helps traders assess how likely their orders are to be filled promptly, which can be critical for strategy adjustments in fast-moving markets. The accuracy of this approximation is contingent upon data quality and platform distribution factors. To configure this feature, users click the trading configuration icon and select 'Orders Queue' to activate queue approximations. This representation is visually depicted by white vertical lines overlaid on the order book histogram, illustrating the order's placement relative to current pending order volume . This feature enhances traders’ ability to manage orders effectively within the scope of prevailing market conditions.

The configuration of one-click trading in BookMap significantly impacts order execution by streamlining the placement of buy and sell orders directly from the chart interface. To enable one-click trading, users must access the trading configuration and enable this feature, specifying the number of contracts per order . Once enabled, traders can place orders with a single click at desired price levels. The efficiency gained from this feature comes with certain considerations: traders should ensure that the specified order size aligns with their risk management guidelines and that their trading strategy is adaptable to the fast execution this feature allows. Additionally, care should be taken in the use of click precision and chart configuration to avoid accidental order placements, especially in volatile markets. Traders should also validate that their platform and connectivity settings are stable to ensure that each click reliably translates to timely market action. Such meticulous preparation helps leverage the swiftness of one-click trading without increasing operational risk.

BookMap Replay can be utilized as a powerful tool for enhancing trading strategies without real-time market exposure by allowing traders to analyze and simulate trading actions in a controlled environment using historical market data. Through BookMap Replay, traders can observe the evolution of market depth and price movements for recorded sessions, enabling them to test hypothetical trading strategies without financial risk . This mode enables the same chart features as live mode, facilitating detailed insights into how strategies perform under various market conditions . Traders can pause, rewind, accelerate, or slow down the replay speed to focus on critical moments, evaluate decision points, and refine entry and exit strategies. This process aids traders in identifying strengths and weaknesses in their approach and informs better strategy development before transitioning to a live environment.

It is important for users to initially use BookMap with a live data feed and a paper trading account before transitioning to a live trading account to minimize financial risk. This approach allows traders to familiarize themselves with the features, functionalities, and potential limitations of BookMap without the pressure and risk of real financial loss . By simulating trades using live market conditions, traders can test their strategies, assess the reliability and accuracy of BookMap's market data visualization, and modify their approach as needed. Such a transition period equips users with experience and confidence in using the tool effectively before executing trades with actual money in a live trading account.

______________________________________________________________________________ 
 
 
 
 
 
 
 
 
BookMap 
User Guide
______________________________________________________________________________ 
Page1of13 
 
Introduction 
BookMap is an inno
______________________________________________________________________________ 
Page2of13 
 
Importing BookMap Live 
Before r
______________________________________________________________________________ 
Page3of13 
c.) Right click on the chart and c
______________________________________________________________________________ 
Page4of13 
f.) After you entered the list of
______________________________________________________________________________ 
Page5of13 
 
BookMap Live 
General Orientatio
______________________________________________________________________________ 
Page6of13 
b) The green and blue bars to the
______________________________________________________________________________ 
Page7of13 
 
Placing Orders: 
Note: the secti
______________________________________________________________________________ 
Page8of13 
 
Order Status: 
a) Cyan circle ma
______________________________________________________________________________ 
Page9of13 
 
BookMap Live with pending, cance

You might also like