Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Drawing Tools - Arrows

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

    Drawing Tools - Arrows

    Has anyone come across anything tha lets you draw smaller arrow heads than what's offered with the current arrow offered in the drawing tool. The arrow head is huge!

    I guess an alternative would be to use Snagit to capture a chart and uses their drawing tools!

    Seems like this would be easy to address by offering a few different arrow head sizes.

    TIA

    D

    #2
    Hello dmking,

    Thanks for your post.

    I will submit a feature request to development to be able to adjust the size of drawing objects.

    Comment


      #3
      I am testing out NT8 and have created a simple script that draws an arrow whenever there is a cross above the swing high. However I am only getting 1 arrow (most recent) whereas I would like to see all the recent arrows.

      Thanks


      #region Using declarations
      using System;
      using System.Collections.Generic;
      using System.ComponentModel;
      using System.ComponentModel.DataAnnotations;
      using System.Linq;
      using System.Text;
      using System.Threading.Tasks;
      using System.Windows;
      using System.Windows.Input;
      using System.Windows.Media;
      using System.Xml.Serialization;
      using NinjaTrader.Cbi;
      using NinjaTrader.Gui;
      using NinjaTrader.Gui.Chart;
      using NinjaTrader.Gui.SuperDom;
      using NinjaTrader.Gui.Tools;
      using NinjaTrader.Data;
      using NinjaTrader.NinjaScript;
      using NinjaTrader.Core.FloatingPoint;
      using NinjaTrader.NinjaScript.DrawingTools;
      #endregion

      //This namespace holds Indicators in this folder and is required. Do not change it.
      namespace NinjaTrader.NinjaScript.Indicators
      {
      public class FTRnBarBreak : Indicator
      {
      private Swing Swing1;
      private VOL VOL1;
      private Bollinger Bollinger1;
      protected override void OnStateChange()
      {
      if (State == State.SetDefaults)
      {
      Description = @"Enter the description for your new custom Indicator here.";
      Name = "FTRnBarBreak";
      Calculate = Calculate.OnBarClose;

      DisplayInDataBox = true;
      DrawOnPricePanel = true;
      DrawHorizontalGridLines = true;
      DrawVerticalGridLines = true;
      PaintPriceMarkers = true;
      ScaleJustification = NinjaTrader.Gui.Chart.ScaleJustification.Right;
      IsOverlay = true;
      //Disable this property if your indicator requires custom values that cumulate with each new market data event.
      //See Help Guide for additional information.
      IsSuspendedWhileInactive = true;


      }
      else if (State == State.Configure)
      {
      Swing1 = Swing(5);
      VOL1 = VOL();
      Bollinger1 = Bollinger(VOL(),1,90);
      }
      }

      protected override void OnBarUpdate()
      {
      //Add your custom indicator logic here.
      if ((CrossAbove(Close, Swing1.SwingHigh, 1)))

      {
      Draw.ArrowUp(this, "MyCustomStrategy1 Arrow up", false, 0, Low[0] - (2 * TickSize), new SolidColorBrush(Colors.Lime));
      }
      }
      }
      }

      #region NinjaScript generated code. Neither change nor remove.

      namespace NinjaTrader.NinjaScript.Indicators
      {
      public partial class Indicator : NinjaTrader.Gui.NinjaScript.IndicatorRenderBase
      {
      private FTRnBarBreak[] cacheFTRnBarBreak;
      public FTRnBarBreak FTRnBarBreak()
      {
      return FTRnBarBreak(Input);
      }

      public FTRnBarBreak FTRnBarBreak(ISeries<double> input)
      {
      if (cacheFTRnBarBreak != null)
      for (int idx = 0; idx < cacheFTRnBarBreak.Length; idx++)
      if (cacheFTRnBarBreak[idx] != null && cacheFTRnBarBreak[idx].EqualsInput(input))
      return cacheFTRnBarBreak[idx];
      return CacheIndicator<FTRnBarBreak>(new FTRnBarBreak(), input, ref cacheFTRnBarBreak);
      }
      }
      }

      namespace NinjaTrader.NinjaScript.MarketAnalyzerColumns
      {
      public partial class MarketAnalyzerColumn : MarketAnalyzerColumnBase
      {
      public Indicators.FTRnBarBreak FTRnBarBreak()
      {
      return indicator.FTRnBarBreak(Input);
      }

      public Indicators.FTRnBarBreak FTRnBarBreak(ISeries<double> input )
      {
      return indicator.FTRnBarBreak(input);
      }
      }
      }

      namespace NinjaTrader.NinjaScript.Strategies
      {
      public partial class Strategy : NinjaTrader.Gui.NinjaScript.StrategyRenderBase
      {
      public Indicators.FTRnBarBreak FTRnBarBreak()
      {
      return indicator.FTRnBarBreak(Input);
      }

      public Indicators.FTRnBarBreak FTRnBarBreak(ISeries<double> input )
      {
      return indicator.FTRnBarBreak(input);
      }
      }
      }

      #endregion
      Last edited by brucelevy; 06-04-2016, 06:45 PM.

      Comment


        #4
        Originally posted by brucelevy View Post
        I am testing out NT8 and have created a simple script that draws an arrow whenever there is a cross above the swing high. However I am only getting 1 arrow (most recent) whereas I would like to see all the recent arrows.

        Thanks
        They need unique names...

        Code:
        Draw.ArrowUp(this, "MyCustomStrategy1 Arrow up"+CurrentBar, ...



        tag
        A user defined unique id used to reference the draw object. For example, if you pass in a value of "myTag", each time this tag is used, the same draw object is modified. If unique tags are used each time, a new draw object will be created each time.

        Comment


          #5
          So is it possible for them not to be unique so it displays all of them?

          Comment


            #6
            Originally posted by brucelevy View Post
            So is it possible for them not to be unique so it displays all of them?
            No. Not on this platform.

            Comment


              #7
              That does not make any sense, maybe I am not explaining myself correctly.

              I want to display an up arrow everytime the close crosses above the prior swing high.

              Comment


                #8
                Originally posted by brucelevy View Post
                That does not make any sense, maybe I am not explaining myself correctly.

                I want to display an up arrow everytime the close crosses above the prior swing high.
                I mentioned this below based on your code:

                Code:
                Draw.ArrowUp(this, "MyCustomStrategy1 Arrow up"[B]+CurrentBar,[/B] ...
                This would make each one "unique" and NT will display them all.

                They can not be named the same thing. If they are named the same thing, you will only see the latest one, as you have seen.

                Comment


                  #9
                  Thanks Sledge, I see I had overlooked +CurrentBar

                  Comment


                    #10
                    Originally posted by brucelevy View Post
                    So is it possible for them not to be unique so it displays all of them?
                    Your current code answers that question, so why do you ask it?

                    In your current code, the tags are not unique. Does it show them all?

                    Comment


                      #11
                      Originally posted by koganam View Post
                      Your current code answers that question, so why do you ask it?

                      In your current code, the tags are not unique. Does it show them all?
                      I answered below:



                      It's a valid question with or without the current code.

                      There could be some checkbox somewhere in the not so vast (but somewhat obscure) options in NT... especially NT8...

                      Comment


                        #12
                        Originally posted by sledge View Post
                        I answered below:



                        It's a valid question with or without the current code.
                        Granted, but the current code does exist, so it is pointless asking whether it is possible to use that current code to show that which it has already shown that it will not. There is one absolute given with a computer program: if the program is not using randomized elements, then it is deterministic in an absolute sense; and will always produce the same result from the same inputs. As a matter of fact, if it does not, that in itself points to an almost certain hardware issue.

                        Comment


                          #13
                          Originally posted by koganam View Post
                          Granted, but the current code does exist, so it is pointless asking whether it is possible to use that current code to show that which it has already shown that it will not. There is one absolute given with a computer program: if the program is not using randomized elements, then it is deterministic in an absolute sense; and will always produce the same result from the same inputs. As a matter of fact, if it does not, that in itself points to an almost certain hardware issue.
                          Well, I'm somewhat of a "hacker"... so there are always some sort of possibilities.

                          Don't make me go OllyDbg on this... I'll find a back door mod...

                          Comment


                            #14
                            Originally posted by sledge View Post
                            Well, I'm somewhat of a "hacker"... so there are always some sort of possibilities.

                            Don't make me go OllyDbg on this... I'll find a back door mod...
                            Well, if you want to mod the NT files themselves, to find the Draw() code and modify it so that it no longer sees the tag as a unique identifier ... Just remember that this is not NT8, so you cannot see the source code directly.

                            Comment


                              #15
                              brucelevy.

                              Though your question is answered already there is a private bool I use to differentiate between present arrows and past arrows. That allows me to only have the present arrows show up (which is what I usually prefer) but now and then I want to see the past ones as well. I also added RemoveDrawObject for the opposite condition which is useful when the condition changes within the same bar. Anyway, may or may not be something useful for you, but I thought I'd mention it.

                              MY CONDITION
                              {
                              DrawArrowUp("Arrow Up", false, 0, Low[0] - drawplace *TickSize, upsym);
                              RemoveDrawObject ("Arrow Down");

                              if (showpastArrows_On) DrawArrowUp("Arrow Up" + CurrentBar, false, 0, Low[0] - drawplace *TickSize, upsym);
                              }

                              sandman
                              Last edited by sandman; 06-05-2016, 03:45 PM.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by argusthome, 03-08-2026, 10:06 AM
                              0 responses
                              116 views
                              0 likes
                              Last Post argusthome  
                              Started by NabilKhattabi, 03-06-2026, 11:18 AM
                              0 responses
                              61 views
                              0 likes
                              Last Post NabilKhattabi  
                              Started by Deep42, 03-06-2026, 12:28 AM
                              0 responses
                              40 views
                              0 likes
                              Last Post Deep42
                              by Deep42
                               
                              Started by TheRealMorford, 03-05-2026, 06:15 PM
                              0 responses
                              43 views
                              0 likes
                              Last Post TheRealMorford  
                              Started by Mindset, 02-28-2026, 06:16 AM
                              0 responses
                              82 views
                              0 likes
                              Last Post Mindset
                              by Mindset
                               
                              Working...
                              X