NexusFi: Find Your Edge


Home Menu

 





ContainsValue question


Discussion in Platforms and Indicators

Updated
    1. trending_up 1,579 views
    2. thumb_up 2 thanks given
    3. group 2 followers
    1. forum 3 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
 solondon 
London, UK
 
Experience: Intermediate
Platform: ninja,TS,Meta,Tradeguider
Trading: FX,Metals
Posts: 38 since Sep 2011
Thanks Given: 9
Thanks Received: 6

Hi,

can anyone tell me what im doing wrong with this , in my debugging i use the following (same parameters)

" EMAflat: " + EMA_Colors(m_EmaAngle1,m_EmaAngle2,slowAverage).EMAflat[0].ToString()
+ " ContainsValue: " + EMA_Colors(m_EmaAngle1,m_EmaAngle2,slowAverage).EMAflat.ContainsValue(0).ToString()

it prints

August 02, 2013 9:24:26 OnBarUpdate() - adxSetup[0]: 1 adxEntry[0]: 1 bBuySetup: True bBuyEntry: True bSellSetup: False bSellEntry: False EMAflat: 1.3224 ContainsValue: False

I can see that the bar has a value for EMAFlat but i cant explain how both conditions can be true at the same time ie. it has a value but ContainsValue says it doesnt. is the call to the indicator plot value not treated as a dataseries or am i missing something! (too many hours today)

thanks in advance
Jlo


Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
CFTC Rewrites the Rulebook -- Kalshi Cracks $1B Non-Spor …
Prediction Markets & Event Contracts
April FOMC Minutes: Most Divided Fed Since 1992 -- Many …
Traders Hideout
$12M Ceasefire Contract Goes Disputed as Bandar Abbas St …
Prediction Markets & Event Contracts
Probability Collapse: Bitcoin $150k Craters from 15% to …
Prediction Markets & Event Contracts
Asia Equities Crash Overnight -- Nikkei -5.2%, KOSPI -6. …
Traders Hideout
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
21 thanks
2026 Jlab journal
10 thanks
Trying to learn Volume and price action correlation
8 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Hello Im new here
5 thanks
  #3 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader
Broker: Interactive Brokers
Trading: Futures & Stocks
Posts: 9,887 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,114


In case that

- no value has been affected to a DataSeries object for a specific bar
- or that you have reset the DataSeries for that bar

the DataSeries will still contain an object. Consider this object as a dummy or placeholder. Usually the dummy value is the close of the referenced bar.

The property "ContainsValue" holds the information, whether the object has been created by the user.

If "ContainsValue" returns the value "False", it simply means that the value stored in the DataSeries field is a dummy.


If you produce code it is your responsibility

-> to make sure that all all DataSeries fields that you want to access hold proper values
-> that you set those values in a proper way


Reply With Quote
Thanked by:
  #4 (permalink)
 solondon 
London, UK
 
Experience: Intermediate
Platform: ninja,TS,Meta,Tradeguider
Trading: FX,Metals
Posts: 38 since Sep 2011
Thanks Given: 9
Thanks Received: 6

thanks usefull information, I guess this is the hazard of using other peoples indicators


Started this thread Reply With Quote




Last Updated on August 6, 2013


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts