Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Buy sell volume relies on bid/ask tick updates expecting Calculate 'On each tick'

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Buy sell volume relies on bid/ask tick updates expecting Calculate 'On each tick'

    Hi there - I'm trying to set up a simple strategy that checks returns on long positions entered at 12pm and exited at 3pm, if Buy Volume is greater than Sell Volume. However I keep getting the error "Buy sell volume relies on bid/ask tick updates expecting Calculate 'On each tick' Error".

    I've read a lot of the other posts about this but cannot resolve. I have my strategy set to calculate based on "On each tick", but still receive this error and my strategy returns 0 results.

    Attached is my code line. Any suggestions?

    Thanks!
    Attached Files

    #2
    Hello WillMont10,

    Thanks for your post.

    I have created a copy of the code you shared and when I enable the strategy on a New > Chart window, I do not see any error messages appear. See the attached image.

    Please answer the following questions.
    • What version of NinjaTrader are you using? Please provide the entire version number. This can be found under Help -> About (Example: 7.0.1000.? or 8.0.?.?)​
    • What exact steps and settings did you use to reproduce the error when testing the attached script?
    • Please also provide me with an exported copy of the script to test using the exact steps and settings you provide.
    Note that if a strategy is not placing orders as expected, you should add debugging prints to the script to understand how it is calculating logic and placing trades.

    It is also important to note that the BuySellVolume indicator assigns both the buys and sells to the Buys plot. This could be seen by looking at the code of the BuySellVolume indicator in a New > NinjaScript Editor window.

    You would need to subtract the Sells from the Buys plot to get only the Buys from the indicator. See the attached image.

    Below is a link to a forum post that demonstrates how to use prints to understand behavior.
    https://ninjatrader.com/support/foru...121#post791121

    Please let me know if I may assist further.​
    Attached Files
    Last edited by NinjaTrader_BrandonH; 03-05-2023, 06:20 PM.
    <span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, 03-13-2026, 05:17 AM
    0 responses
    96 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    154 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    82 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    54 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    72 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X