Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using Strategy in Workspace

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

    Using Strategy in Workspace

    Hello,

    I have strategy which work in Strategy Analyzer. But when I try use the same strategy in my workspace, nothing happend od my chart. There is no information about any problem. For the first view it looks that everything is all right, but strategy doesn't color bars (strategy should color bars which do properly conditions).

    This is the code:

    protected override void OnBarUpdate()
    {
    // Condition set 1

    if (CurrentBar < 60)
    return;


    if (Close[0] > Close[20]
    && Close[0] > Close[60])
    {
    BarColor = Color.Green;

    }
    if (Close[0] < Close[20]
    && Close[0] < Close[60])
    {
    BarColor = Color.Red;

    }

    }


    Please, help me.

    Thanks
    Daniel

    #2
    Daniel, after applying and enabling the strategy (for NT7) - do you see any errors shown in the log tab of the Control Center?

    Thanks,
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Hello,

      I am using NT 6.5 and there is no information about errors in log tab.

      I checked other strategy and it also doesn't work.

      Daniel

      Comment


        #4
        Do you run this from the chart directly or from the strategies tab in the Control Center?

        Strategies started from the tab would not be visualized on the chart.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          I started on the chart.

          File/new/chart... then I chose index S&P daily. When the bars are uploaded I click on the icon (yellow circle with "s" inside) and I chose my strategy. I clicked "OK" and nothing happend.

          Daniel

          Comment


            #6
            That would be unfortunately expected for NinjaTrader 6.5, backtesting on indices data would not be supported - if you change for example to SPY or INTC stocks it would work, correct?
            BertrandNinjaTrader Customer Service

            Comment


              #7
              Sorry but I dont understand. Can you tell me what "SPY or INTC" mean?

              Comment


                #8
                Those are just regular stocks / ETF's, the INTC (Intel) stock is for example on your DOW30 instrument list.
                BertrandNinjaTrader Customer Service

                Comment


                  #9
                  It still doesn't work. I connected with yahoo and I open chart of INTC and I run my strategy and still nothing. Maybe I can send you my strategy and you will be able to check it on your software?

                  Daniel

                  Comment


                    #10
                    For sure, you can export it and attach it here or please send me a note to support at ninjatrader dot com with the file to test - to compare : would the SampleMACrossover work as expected on your Yahoo daily stock charts?

                    Thanks,
                    BertrandNinjaTrader Customer Service

                    Comment


                      #11
                      Hello,

                      I am sending strategy as the attachment. SampleMACrossover doesn't work as well.

                      Daniel
                      Attached Files

                      Comment


                        #12
                        Hello Danielj,

                        It works OK here. I'm getting some color changes to bars.

                        and I chose my strategy. I clicked "OK" and nothing happend.

                        Is the strategy actually applied to a chart? Double click in the list to add it to the chart and it will show up in the window at the bottom. Screenshot attached to verify it's applied to the chart.
                        Attached Files
                        Last edited by NinjaTrader_RyanM1; 11-30-2010, 02:08 PM.
                        Ryan M.NinjaTrader Customer Service

                        Comment


                          #13
                          Sorry for taking your time. I didin't click twice...Sorry. It is ok now.

                          Thanks
                          Daniel

                          Comment

                          Latest Posts

                          Collapse

                          Topics Statistics Last Post
                          Started by cre8able, Today, 03:20 PM
                          1 response
                          9 views
                          0 likes
                          Last Post cre8able  
                          Started by fiddich, Today, 05:25 PM
                          0 responses
                          3 views
                          0 likes
                          Last Post fiddich
                          by fiddich
                           
                          Started by gemify, 11-11-2022, 11:52 AM
                          6 responses
                          804 views
                          2 likes
                          Last Post ultls
                          by ultls
                           
                          Started by ScottWalsh, Today, 04:52 PM
                          0 responses
                          4 views
                          0 likes
                          Last Post ScottWalsh  
                          Started by ScottWalsh, Today, 04:29 PM
                          0 responses
                          9 views
                          0 likes
                          Last Post ScottWalsh  
                          Working...
                          X