Login / Register
Add a review
Log in
Sign UP
OrderBook Utilities


OrderBook Utilities is a script that performs several auxiliary operations with the hob files of the glass history saved using OrderBook Recorder.

The script processes the file for the working symbol of the current chart. A specific file is determined using the CustomDate parameter (if it is filled in) or by the point at which the script resets to the graph. Depending on the operation, the processing result is written only to the log, or to the log and output file.

The operation is selected using the Operation parameter:

  • Check Check-checks the records for correctness; for various reasons, incorrect glasses can get into the terminal quite often; possible errors that need to be corrected are listed below; the Check operation does not correct errors, but only displays their statistics in the log; to display details, you should enable PrintDetails mode; in addition to errors, the operation displays statistics on glasses with zero spread and glasses in which Bid and/or Ask price levels overlap the opposite half of purchases and / or sales; see examples on the Discussion tab;
  • Fix fix-fixes the file by discarding erroneous entries; removes both serious and minor errors (see classification below); the corrected version is written to a file of the same name with the double extension. hob. fix;
  • Pack – compaction of the file, may be useful before transferring it to someone in order to reduce traffic; the compressed file has an extension.hop;
  • Unpack Unpack-restore a hob file from a compressed hop file;
  • Export – saving information in text form, in a csv file; it can be convenient for editing, contextual comparison, merging;
  • Import-restore a hob file from an exported csv file;

[spoiler title=”

Serious errors are marked in bold.

  • Consecutive identical glasses, i.e. no changes;
  • The order of the Sell and Buy levels is broken, i.e. they do not form strictly 2 halves, each of which contains only orders of the same type;
  • Broken order of sorting prices in one of the halves of the glass;
  • Completely duplicate items in the glass, i.e. with equal types and prices;
  • Empty glass;
  • Glass with one level;

If there are serious errors, it is not possible to perform packaging.

  • Operation – operation type, one of: Check (default), Fix, Pack, Unpack, Export, Import;
  • FileFolder – the name of the root folder where the subfolders with the glass files are located; by default, “Books”; each subfolder is named by the symbol name;
  • UseCommonFiles – option to read files from the current terminal folder (false, default) or from the shared folder of all terminals (true);
  • CustomDate – the day that identifies the working hob file (files are created on the principle of one day = one file); by default-0 (displayed in the MT5 interface as ‘1970.01.01 00:00:00’), which means that the day will be selected based on the point on the chart where the script was run; for example, if the script was dragged with the mouse from the navigator and released on the bars for the 2018.08.01 number, the 20180801 file will be processed.hob; if the CustomDate parameter is filled with a specific date, then the reset point of the script no longer matters;
  • MinimalBookSizeFilter – the minimum size of the glass that will be saved during the Fix operation, by default-0, i.e. there is no filter, and glasses of all sizes are saved;
  • PrintDetails – option to enable a more detailed log, by default – false;


Add review
Reviews ( 0 ):