Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How do I change the pen while plotting

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

    How do I change the pen while plotting

    PlotColors is very convenient.

    I have an odd, but quite similar requirement -- I would like most of my plot to be a solid line (or whatever else the user configures), but I want the last part of my plot to be dashes.

    Is there an easy way to do that?

    I could plot two lines and for each bar use PlotColors to set the one I do not want to show to Transparent. The problem with that is it will put a confusing duplicate entry in Data Box. The only way to keep it out of Data Box is to set its base pen to Transparent -- but if I do that, it will not plot at all, regardless of what I do in PlotColors.

    Help!
    EV

    #2
    Unfortunately there is no way to do this. You can only select one plot style for the whole plot.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_Josh View Post
      Unfortunately there is no way to do this. You can only select one plot style for the whole plot.
      Sounds like the old red/green coloring back before you had PlotColors.

      Aaargh! The reason I want to do this is that for a displaced moving average, the last <displacement> bars are ones that are estimated, not real, so they should be displayed differently. I want to continue the bull/bear coloring, so using color is not an option.

      I could use my two-plot solution if it were not that Data Box display and whether or not to plot are driven by side effects. If I could directly control whether or not Data Box shows the plot, and whether or not it actually gets plotted this would all work.

      Not to beat a dead horse, but this is another example of why Computer Science 101 says not to do things by side effects -- that is an EVIL design. They can work well when all is as the originator intended -- however there are bound to be things that were unforeseen, as in this case.

      Even with the side effects, this would work if the decision whether to display actually plot was made bar-by-bar on the combination of the plot color and the PlotColors entry for that bar, rather than just the color of the basic pen for the plot. This issue was brought up by someone else in an earlier thread.

      My request:
      1) First choice is to lose the dependence on side effects
      2) My second choice would be to control whether or not to actually plot bar-by-bar.

      A Pen data series that could be used in lieu of PlotColors would solve this problem, too. I'm not sure it would be worth much effort on your part, though, since this is a pretty unusual case.

      --EV

      Comment


        #4
        Unfortunately this is not possible. Options available to you are all or nothing.

        If you are willing to just turn it completely off the data box you can use DisplayInDataBox = false.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Originally posted by NinjaTrader_Josh View Post
          If you are willing to just turn it completely off the data box you can use DisplayInDataBox = false.
          Sorry -- no can do -- that turns off display of the whole indicator.

          I've got two options in mind, one of which is to put up with the extraneous display in Data Box.

          I sure hope you get out of the side effects business in a future release.

          --EV

          Comment


            #6
            Unfortunately not following you what you mean by "side effect" business. You are trying for a usage model that it simply was never designed for and as such it is not possible to do.
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              Josh,

              Let's just leave it that I think NT has done a great job with its framework, in spite of the fact that there are a couple of things I want to see improved.

              I understand the current situation with respect to what I "need" to do. I'll email you about anything else.

              Thanks for the help,
              EV

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
              0 responses
              576 views
              0 likes
              Last Post Geovanny Suaza  
              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
              0 responses
              334 views
              1 like
              Last Post Geovanny Suaza  
              Started by Mindset, 02-09-2026, 11:44 AM
              0 responses
              101 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
              0 responses
              553 views
              1 like
              Last Post Geovanny Suaza  
              Started by RFrosty, 01-28-2026, 06:49 PM
              0 responses
              551 views
              1 like
              Last Post RFrosty
              by RFrosty
               
              Working...
              X