Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Indexing Volumetric TotalBuying/TotalSelling Volume

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

    Indexing Volumetric TotalBuying/TotalSelling Volume

    Hi All,

    I apologize as I'm doing fine indexing the price-related volumetric properties (Ex: barstype.Volumes[CurrentBar].GetBidVolumeForPrice[Highs[14][0] functions fine), but when it comes to accessing "barsType.Volumes[CurrentBar].TotalBuyingVolume" in a multi-timeframe script I'm running into a barrier properly indexing. Can you please point me in the right direction?

    Using Calculate.OnBarClose, what I'm looking to accomplish in a strategy script is to compare an indexed instrument's last bar [0] to it's preceding bar [1] to see if the TotalBuyingVolume of [0] is greater than the TotalSellingVolume of [1].

    Example using the 2nd instrument in index:

    barsType.Volumes[CurrentBar].TotalBuyingVolume(Closes[2][0]) > barsType.Volumes[CurrentBar].TotalSellingVolume(Closes[2][1])

    However, this throws the "cannot be used like a method" error, and unless I'm missing it I couldn't pass through a (BarsArray[2][0]) anywhere, either. I've tried multiple different combinations, swapped in CurrentBars, read a bunch of threads, and am unfortunately still missing something.

    Thoughts on how to accomplish this? Your input is much appreciated.

    Thanks

    #2
    Hello jeh007258,

    Thank you for your note.

    Can you give a larger code example showing the instruments being added and the logic you're using to access the volumetric bar information? Are you adding volumetric series and accessing that?

    Thanks in advance; I look forward to assisting you further.
    Kate W.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Option Whisperer, Today, 09:55 AM
    0 responses
    4 views
    0 likes
    Last Post Option Whisperer  
    Started by geddyisodin, 04-25-2024, 05:20 AM
    8 responses
    58 views
    0 likes
    Last Post NinjaTrader_Gaby  
    Started by halgo_boulder, 04-20-2024, 08:44 AM
    2 responses
    22 views
    0 likes
    Last Post halgo_boulder  
    Started by mishhh, 05-25-2010, 08:54 AM
    19 responses
    6,189 views
    0 likes
    Last Post rene69851  
    Started by gwenael, Today, 09:29 AM
    0 responses
    6 views
    0 likes
    Last Post gwenael
    by gwenael
     
    Working...
    X