NexusFi: Find Your Edge


Home Menu

 





tweezer


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one sam028 with 1 posts (1 thanks)
    2. looks_two abiritus with 1 posts (0 thanks)
    3. looks_3 traderwerks with 1 posts (0 thanks)
    4. looks_4 Quick Summary with 1 posts (0 thanks)
    1. trending_up 2,187 views
    2. thumb_up 1 thanks given
    3. group 3 followers
    1. forum 3 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
abiritus
israel
 
Posts: 4 since Dec 2009
Thanks Given: 4
Thanks Received: 1

I would like to draw a line betweene each tweezer(two same hight bars or two same low bars )
the programe :
// Check for Tweezer pattern
protected override void Initialize()
{
CalculateOnBarClose = true;
Overlay = true;
PriceTypeSupported = false;
}

protected override void OnBarUpdate()
{
if (CurrentBar < 2) return;
if (High[0] == High[1])
DrawLine("tag1",true, 2, High[0], 0, High[1], Color.Magenta, DashStyle.Solid, 5);
if (Low[0] == Low[1])
DrawLine("tag1",true, 2, Low[0], 0, Low[1], Color.Magenta, DashStyle.Solid, 5);
}
the result: only one line was drawn and i want that all two same higts and each two same lowers bars will be drawn in the chart
can someone helps ?


Reply With Quote

Can you help answer these questions
from other members on NexusFi?
[WTS] ATAS Lifetime ULTRA license – EU buyers only – …
Platforms and Indicators
AI for Traders — Agents, Memory, Tools & Real-Worl …
Elite Quantitative GenAI/LLM
What we know about Binances $6.3bn hack - BBC News
Cryptocurrency
No book, only a stair: journaling fills where price move …
Cryptocurrency
requesting .nrd replay files from 2026 spy and qqq
The Elite Circle
 
  #3 (permalink)
 
sam028's Avatar
 sam028 
Site Administrator
 
Posts: 3,779 since Jun 2009
Thanks Given: 3,840
Thanks Received: 4,709


Add an unique tag for each DrawLine, not a simple "tag1".


Success requires no deodorant! (Sun Tzu)
Reply With Quote
Thanked by:
  #4 (permalink)
 traderwerks   is a Vendor
 
Posts: 688 since Jun 2009
Thanks Given: 436
Thanks Received: 466

Something like
 
Code
"Tweezer" + CurrentBar
for the tag.


Math. A gateway drug to reality.
Reply With Quote




Last Updated on August 22, 2011


© 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