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

Added Plots and new version not seen in Indicator List?

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

    Added Plots and new version not seen in Indicator List?

    I am trying to add plots to the open source VPA indicator so they are public and seen in Market Analyzer, Strategy Builder , and Chart alerts. After adding the plots below, saving , and compiling the new version is not seen in the Indicator List?

    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "upThrustConditionOne");
    AddPlot(new Stroke(Brushes.Red ,-1), PlotStyle.Dot, "upThrustConditionTwo");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "upThrustConditionThree");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "reversalLikelyBar");
    AddPlot(new Stroke(Brushes.LimeGreen ,1), PlotStyle.Dot, "isStrengthConfirmationBar");
    AddPlot(new Stroke(Brushes.Yellow , 1), PlotStyle.Dot, "stopVolBar");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "noDemandBar");
    AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "noSupplyBar");
    AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "supplyTestInUpTrendBar");
    AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "successfulSupplyTestBar");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "failedEffortUpMove")
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "effortDownMove");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "isUpThrustBar")
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "isConfirmedUpThrustBar");
    AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "effortUpMoveBar");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "weaknessBar");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "distributionBar");
    AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "pseudoUpThrustConfirmation");
    AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "effortUpMoveBar");

    Attached Files

    #2
    Hi Tradarr, thanks for your post.

    Please look to the Log tab of the Control Center. Do you have any initialization errors coming from the indicator?

    I look forward to hearing from you.
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by Tradarr View Post
      I am trying to add plots to the open source VPA indicator so they are public and seen in Market Analyzer, Strategy Builder , and Chart alerts. After adding the plots below, saving , and compiling the new version is not seen in the Indicator List?

      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "upThrustConditionOne");
      AddPlot(new Stroke(Brushes.Red ,-1), PlotStyle.Dot, "upThrustConditionTwo");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "upThrustConditionThree");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "reversalLikelyBar");
      AddPlot(new Stroke(Brushes.LimeGreen ,1), PlotStyle.Dot, "isStrengthConfirmationBar");
      AddPlot(new Stroke(Brushes.Yellow , 1), PlotStyle.Dot, "stopVolBar");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "noDemandBar");
      AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "noSupplyBar");
      AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "supplyTestInUpTrendBar");
      AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "successfulSupplyTestBar");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "failedEffortUpMove")
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "effortDownMove");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "isUpThrustBar")
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "isConfirmedUpThrustBar");
      AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "effortUpMoveBar");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "weaknessBar");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "distributionBar");
      AddPlot(new Stroke(Brushes.Red , -1), PlotStyle.Dot, "pseudoUpThrustConfirmation");
      AddPlot(new Stroke(Brushes.LimeGreen , 1), PlotStyle.Dot, "effortUpMoveBar");
      From your file:
      Code:
              [Display(Name="Font", Description="Message Font", Order=13, GroupName="Parameters")]
              public SimpleFont Font { get; set; }
      
              [Browsable(false)]
              [XmlIgnore]
              public Series<double> VolumeEma
              {
                  get { return Values[0]; }
              }
      
              [Browsable(false)]
              [XmlIgnore]
              public Series<double> Strong
              {
                  get { return Values[1]; }
              }
      
              [Browsable(false)]
              [XmlIgnore]
              public Series<double> Weak
              {
                  get { return Values[2]; }
              }
      
              [Browsable(false)]
              [XmlIgnore]
              public Series<double> StrongWeak
              {
                  get { return Values[3]; }
              }
      You have defined properties for only 4 plots. Just declaring the Plots is not sufficient: you have to assign values to the underlying fields, and also expose the Plots as properties.

      Comment


        #4
        Thanks I will correct and add here and user share site if allowed.

        Comment


          #5
          Originally posted by NinjaTrader_ChrisL View Post
          Hi Tradarr, thanks for your post.

          Please look to the Log tab of the Control Center. Do you have any initialization errors coming from the indicator?

          I look forward to hearing from you.
          I made made changes, compiled ok, but the indicator is not seen in Indicator list, now I see error regarding unique naming in picture? Code Attached .
          Attached Files

          Comment


            #6
            Originally posted by Tradarr View Post

            I made made changes, compiled ok, but the indicator is not seen in Indicator list, now I see error regarding unique naming in picture? Code Attached .
            2 things.
            1. It seems your file name does not match your class name. Look in the editor tab name to see what the actual file name of your class VPAv2 is. Alternatively, Use the popup menu to "Save as ..." to save to the name that you want to see (in this case, the class name, I would presume).
            2. Your error is referencing the VPA class, but the file you just posted is (in the file text) called VPAv2. As a start, you may want to find the file that has the text "class VPA" contained in it, and delete that file from the file system.

            Comment


              #7
              Hi Tradarr, thanks for your patience.

              It does look like the original "VPA" script has errors and will need to be reverted to the original copy (Multiple calls to AddPlot with the same plot name). When you need to make a copy of a script, right-click within the original code and select "Save As" and give it a different name. The class name will also be changed for convenience.

              Once the original VPA indicator is compiling and the copy of VPA is made properly you can add the public properties like koganam suggested. This will make the plots accessible to other objects.

              Kind regards,

              -ChrisL
              Chris L.NinjaTrader Customer Service

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by llanqui, Today, 03:53 AM
              0 responses
              4 views
              0 likes
              Last Post llanqui
              by llanqui
               
              Started by burtoninlondon, Today, 12:38 AM
              0 responses
              10 views
              0 likes
              Last Post burtoninlondon  
              Started by AaronKoRn, Yesterday, 09:49 PM
              0 responses
              14 views
              0 likes
              Last Post AaronKoRn  
              Started by carnitron, Yesterday, 08:42 PM
              0 responses
              11 views
              0 likes
              Last Post carnitron  
              Started by strategist007, Yesterday, 07:51 PM
              0 responses
              14 views
              0 likes
              Last Post strategist007  
              Working...
              X