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

Ray by special plots

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

    Ray by special plots

    Hello,

    I need to add something to plotted rays from my indicators to have additional information to know easily where this drawing comes from.

    Therefore I want to ask please

    a.) how one can plot a ray with triangles or diamonds please
    or the other idea

    b.) how can one add letters "A" or "B".... below or above the line-ray at each dash or bar

    I read somewhere in the forum that plotting takes more ressources from the pc. Is the idea with letters EACH dash more intensive for the ressources of pc than a letter only the first bar?

    Thank you
    Tony
    Last edited by tonynt; 09-20-2018, 10:20 AM. Reason: typing error and clearifiying

    #2
    Hello tonynt,

    Thank you for the post.

    A). You would need to draw the other objects that you want to draw in addition to your Ray. The Ray is not a Plot so it does not have a configurable line. You can make it dashed, dotted or solid but not Triangles or Diamonds, these would have to be separately drawn.

    B). This is something you could also do with the text drawing object in addition to your Ray. For custom plotting, you can also use the Plot override. For an example of the Plot override, you could see the CustomPlotSample that comes with NinjaTrader.

    As far as performance goes, the drawing objects are very minimal but you can see performance impacts when doing things like drawing text on every bar. In that case, rendering from the Plot override would generally be the most efficient way to draw on the chart. You can see the CustomPlotSample that comes with NT for a further example of this.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Tony,
      I recently experimented with labelling lines so I took the liberty to label a ray of an HMA as in the attached cs file.
      Note: StringAlignment.Far is useful when you want the label to the left of the start of the line; Near when you want it to the right end of the line.

      You can of course also replace

      BarsArray[0].Period.ToString()
      with a singular letter or letters e.g. "Tony Up" or "Tony Down".

      Perhaps this example helps.

      sandman
      Attached Files
      Last edited by sandman; 09-21-2018, 10:21 AM.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by ZenCortexCLICK, Today, 04:58 AM
      0 responses
      2 views
      0 likes
      Last Post ZenCortexCLICK  
      Started by sidlercom80, 10-28-2023, 08:49 AM
      172 responses
      2,280 views
      0 likes
      Last Post sidlercom80  
      Started by Irukandji, Yesterday, 02:53 AM
      2 responses
      17 views
      0 likes
      Last Post Irukandji  
      Started by adeelshahzad, Today, 03:54 AM
      0 responses
      4 views
      0 likes
      Last Post adeelshahzad  
      Started by Barry Milan, Yesterday, 10:35 PM
      3 responses
      13 views
      0 likes
      Last Post NinjaTrader_Manfred  
      Working...
      X