NexusFi: Find Your Edge


Home Menu

 





Reloading a chart/indicator programatically to determine dynamic trade parameter


Discussion in NinjaTrader

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




 
Search this Thread
  #1 (permalink)
 tomg1970 
chicago
 
Experience: Beginner
Platform: NinjaTrader, MT4, and TradeStation
Trading: es
Posts: 3 since Oct 2014
Thanks Given: 1
Thanks Received: 0

Hi,

I still consider myself a novice NT7 developer, so maybe this is easier than I think, or maybe it can't be done at all.

I created an indicator that has 1 parameter or setting. This setting really determine how many signals the indicator will show. I have a private variable that counts the number of signals on my chart and plots the signal number along with an arrow, so if I change this parameter to 100 (lets call it minimum trade score) I will have HUNDREDS of signals on a historic 10 day chart. If I change minimum trade score to 500, I may only see 1 or 2 trades on the same 10 day historic chart. Usually I have to find a value somewhere in the middle of 100 and 500, like 350, that will produce 30 signals on a 10 day chart, and I accept this minimum trade score value for creating signals in real-time.

So would much rather have a parameter called something like "Max Signals" and set that value to 30, and when I apply that parameter to my indicator, the indicator behind the scenes would start with minimum trade score value of 100 and store all the signals and scores into an array. Then I would loop through the array and count the number of trades with an increase of increment of 25 to the minimum trade score (100, 125, 150.. up to 500), to find which minimum trade score will produce around 30 trades (or whatever the desired number of trades for the time range on the historic chart), lets lets say 325 is 37 trades, and 350 yields 28 trades. I then plot the minimum trade score of 350 on the chart for informational purposes and reload the chart using that setting, so the chart actually shows 28 signals (arrows). Is this possible?

I figured the only way to make this possible is to load the chart twice. Once to determine all the signals, and the 2nd time to show the chart with the desired number of signals.

Any help would be appreciated.

Thanks.. tom


Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
$500M Riding on World Cup 2026: France/Spain Co-Favored …
Prediction Markets & Event Contracts
Al Arabiya: US-Iran Draft Deal Within Hours Contains Hor …
Prediction Markets & Event Contracts
CME Cuts Precious Metals Margins Up to 21% Starting Toda …
Commodities
Day 97: Israel-Lebanon Ceasefire Struck Overnight -- WTI …
Traders Hideout
Third Circuit Backs Kalshi in Landmark Ruling -- Predict …
Prediction Markets & Event Contracts
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
24 thanks
2026 Jlab journal
10 thanks
Lady Vols Primer: Trading Volatility Journal
8 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Trying to learn Volume and price action correlation
5 thanks




Last Updated on September 28, 2015


© 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