Bid-Ask Snapshot in Price Charts

Two new reserved words have been added to EasyLanguage which allows you to access the current inside Bid and current inside Ask from within a chart:

  • InsideBid
  • InsideAsk

These Bid-Ask values are only real-time snapshot values and do not return historical values. When calculating strategies historically, the values for these new reserved words return the current value for every bar. This means that you cannot historically test strategies based on these values. However, you can use them in calculations, and in strategy order placement.

Using Snapshot Bid & Ask in a Study or Strategy

Two new functions have been added to make it easier to use current Bid - Ask information within a chart:

  • CurrentBid
  • CurrentAsk

With these functions, the current real-time inside Bid and inside Ask are returned only on the current bar, otherwise the close of the bar is returned for each historical bar. This allows you to utilize these values real-time and still calculate useful values historically.

Example:

if Condition1 then

Buy ("Entry Name") next bar at CurrentAsk Limit;

Or

Value1 = CurrentAsk - CurrentBid;