Announcement

Collapse
No announcement yet.

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 sjsj2732, 03-23-2026, 04:31 AM
    0 responses
    78 views
    0 likes
    Last Post sjsj2732  
    Started by NullPointStrategies, 03-13-2026, 05:17 AM
    0 responses
    313 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    315 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    149 views
    1 like
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    115 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Working...
    X