Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

marker size

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

    marker size

    Dear NT8 support
    I am plotting some markers on the chart (see attached). To do that I am using the following code:
    Code:
    AddPlot(new Stroke(Brushes.DarkOrange,3), PlotStyle.Dot, "MyMarker");
    I am finding markers being too small and would like to enlarge them for the following
    Code:
    PlotStyle.Dot, PlotStyle.Block, PlotStyle.Cross
    .Was trying to play with last number in the Stroke (its width), that does not seem to have any effect on size of the marker. Please advise on how to accomplish the task.
    Thank you in advance!
    Attached Files
    Last edited by stasha; 04-02-2022, 04:28 PM.

    #2
    Hello stasha,

    I am finding this has a effect.
    Attached is a test script.

    If you are changing this in State.SetDefaults, keep in mind you would need to remove the instance of the indicator from the Configured list and add a new instance from the Available list to pull the defaults.
    Attached Files
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Thanks a lot Chelsea B.. Your code is working as a constant, but I am trying to change the size dynamically, Get parameter from user and apply it to the marker. That does not work. Sample script is attached.. BTW i paid attention you're using 8.0.0.26, while I am 8.0.0.25 don't think it makes huge difference, just to note.
      So if you use this code, take parameter and apply, the result dos not change.
      Thank you
      Attached Files
      Last edited by stasha; 04-04-2022, 06:20 PM.

      Comment


        #4
        Hello stasha,

        State.SetDefaults is only called when a new instance of the script is added and the defaults are pulled.

        If you want to change a plots .Width dynamically, do this in OnBarUpdate().
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by argusthome, 03-08-2026, 10:06 AM
        0 responses
        69 views
        0 likes
        Last Post argusthome  
        Started by NabilKhattabi, 03-06-2026, 11:18 AM
        0 responses
        42 views
        0 likes
        Last Post NabilKhattabi  
        Started by Deep42, 03-06-2026, 12:28 AM
        0 responses
        24 views
        0 likes
        Last Post Deep42
        by Deep42
         
        Started by TheRealMorford, 03-05-2026, 06:15 PM
        0 responses
        27 views
        0 likes
        Last Post TheRealMorford  
        Started by Mindset, 02-28-2026, 06:16 AM
        0 responses
        54 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Working...
        X