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

Add (Plot) parameters

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

    Add (Plot) parameters

    How do I find the syntax for all the possible parameters for Add (Plot)? I want to control the dash style, color, plot style, width, etc. in the NinjaScript code.

    The Help guide says: "There are many variations of defined plot and line objects that are not documented. We suggest using the NinjaScript indicator wizard to generate your indicator plot and oscillator lines."

    I used the Wizard but did not see these parameters anywhere. They must be documented somewhere, right?

    Thanks,

    Geoff

    #2
    Add (Plot) parameters

    Hello gdstuart,

    Thanks for writing in to our Support team.

    To view these parameters after creating your plots or lines in the wizard, you will need to unlock your code by selecting the Unlock Code button in the Indicator Wizard window.

    In order to do this, you will want to use the NinjaScript Plot class combined with the C# Pen class to get your desired effect. To view all of the different constructors for the Plot class in you can visit our help guide here:
    http://ninjatrader.com/support/helpG...plot_class.htm

    You can view the constructors for the Pen class here:
    https://msdn.microsoft.com/en-us/lib...(v=vs.90).aspx

    You can view the constructors for the Line class here:
    http://ninjatrader.com/support/helpG...line_class.htm

    Using these constructors will allow you to control the color, plot style, and width of the plot:
    Code:
    // Adds a blue cross style plot with a thickness of 3
    Add(new Plot(new Pen(Color.Blue, 3), PlotStyle.Cross, "myPlot"));
    Please let me know if I may be of any further assistance.
    Alan S.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Barry Milan, Yesterday, 10:35 PM
    7 responses
    19 views
    0 likes
    Last Post NinjaTrader_Manfred  
    Started by AttiM, 02-14-2024, 05:20 PM
    10 responses
    179 views
    0 likes
    Last Post jeronymite  
    Started by ghoul, Today, 06:02 PM
    0 responses
    9 views
    0 likes
    Last Post ghoul
    by ghoul
     
    Started by DanielSanMartin, Yesterday, 02:37 PM
    2 responses
    13 views
    0 likes
    Last Post DanielSanMartin  
    Started by DJ888, 04-16-2024, 06:09 PM
    4 responses
    13 views
    0 likes
    Last Post DJ888
    by DJ888
     
    Working...
    X