• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

I cannot get this line plot and show in databox

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

    I cannot get this line plot and show in databox

    the following is the codes trying to plot a horizontal line of yesterday VWAP on today's intraday chart. However, it just cannot get plot on the chart, any idea?

    if (Bars.FirstBarOfSession )
    {

    if (Time[0].DayOfWeek == DayOfWeek.Monday)
    timeOfInterest = new DateTime(Time[0].Year, Time[0].Month, Time[0].Day - 3, 16, 30, 0);
    else
    timeOfInterest = new DateTime(Time[0].Year, Time[0].Month, Time[0].Day - 1, 16, 30, 0);
    }
    barsAgo = GetBar(timeOfInterest) ;


    Plot0.Set(VWAP().VWAPLine[barsAgo]);

    #2
    Any errors in the log tab? Do you include a check for enough CurrentBars at the OnBarUpdate() start? Otherwise you run into issues reaching back at the start of your charts as there're no bars back then to calc for.

    http://www.ninjatrader.com/support/f...ead.php?t=3170
    BertrandNinjaTrader Customer Service

    Comment


      #3
      The message from log tab is that:" Error calling the 'OnBarUpdat' method for indicator on bar 78 :year, month and day parameters describle an unrepresentable datetime" And I run another indicator "SampleGetBar" downloaded from this support forum and see the same message from logtab. What should I do?

      Comment


        #4
        You would need to print out associated values to debug where the issues stems from in your code at this time, I believe you would see this for example for an 'irregular' session day as last Monday (Memorial Day in the US) for example.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          I have code that successfully draws horizontal lines to my indicator panel in "maximum" display mode (right click the verticle axis) but I do not see the lines in a data box. How do I get these horizontal lines to display in a data box?

          Comment


            #6
            That would unfortunately not be possible, only plots could be displayed in the data box.

            More control over the databox contents is on our feedback list for the next major NT version update, I've added your request in.

            Thanks,
            BertrandNinjaTrader Customer Service

            Comment


              #7
              More control of drawing objects is REALLY needed like:
              Show price marker checkbox (including left Y axis if there)
              Show in data box checkbox

              AND MOST ESPECIALLY;

              STOP having the properties box show with either a left click OR a right click. The properties box SHOULD ONLY SHOW with a right click!!! I have hundreds of times brought up the properties box by left clicking on a draw object to move it only to have the damn properties box show up for me to have to click cancel, and then try again which can cause the properties box to appear again, (like when I am in a trade with heat).

              This is NOT a problem with my mouse as I have replaced my mouse. Would you please update the request you put in with this info.




              Anyway Bertrand.... thank you for your reply

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by benjamind10, Today, 07:27 PM
              0 responses
              2 views
              0 likes
              Last Post benjamind10  
              Started by YevhenShynkarenko, Today, 06:07 PM
              0 responses
              4 views
              0 likes
              Last Post YevhenShynkarenko  
              Started by StevenNelson, Today, 04:07 PM
              3 responses
              10 views
              0 likes
              Last Post NinjaTrader_ShawnB  
              Started by Matthew Spositi, Today, 03:28 PM
              2 responses
              8 views
              0 likes
              Last Post Matthew Spositi  
              Started by faisamtrader, Today, 01:30 PM
              2 responses
              20 views
              0 likes
              Last Post NinjaTrader_ChrisL  
              Working...
              X