⚡比卡超⚡

How to query current account balance in backtest?

Programming


Hey, I am new to the platform. 
As title, how can I get current account balance in backtest? 
 
admin

There are several ways to do that:

  1. Extract from 'ab' under on_marketdatafeed. Other attributes of 'ab' includes 'realizedPL', 'unrealizedPL', 'cumDeposit', 'marginUsed', and 'availableBalance'. Please refer to the details at https://algogene.com/TechDoc#StreamDataFeed



  2. Similarly, you can extract from 'ab' under on_bulkdatafeed.


  3. You can call the API function 'getAccountBalance'