• 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

Optimization on Max. R^2 (R-Squared)

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

    Optimization on Max. R^2 (R-Squared)

    Hi!

    I want the optimizer to give me the most linear and steady upward equity curve. I thought R^2 is the right Thing but I think it is not.

    I thought R^2 must be between 0 and 1 but I am getting results with way more than 1. Furthermore, very similar equity curves have very different R^2 values (12 compared to 2).

    1. Can anyone explain what the R^2 optimization exactly does? The formula in NT Help guide is not helpful (where is the difference between "Total Trades" and "Summation of Trades"?)

    2. Does anyone have an optimizer to find the most linear and steady upward equity curve?

    (I found this but unfortunately only for NT7 and was unable to make it work in NT8: https://futures.io/ninjatrader/14852...ion-types.html )

    Thanks in advance!

    #2
    Hello KirkHammett,

    I'm not aware of an existing Optimization Fitness script or Optimizer script with this custom logic for NinjaTrader 8.

    This thread will remain open for any community members that may know of where to obtain this or would like to code this as a convenience for you.

    You can also contact a professional NinjaScript Consultant who would be eager to create or modify this script at your request or assist you with your script. The NinjaTrader Ecosystem has affiliate contacts who provide educational as well as consulting services. Please let me know if you would like our business development follow up with you with a list of affiliate consultants who would be happy to create this script or any others at your request.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Thanks for the reply.

      Can you explain to me, what the R^2-optimization does? I just would like to understand it.

      Comment


        #4
        Hello KirkHammett,

        Max R2 is explained in the helpguide at the following section,
        https://ninjatrader.com/support/help...ingMaxRSquared

        Please let us know if you need further assistance.
        Alan P.NinjaTrader Customer Service

        Comment


          #5
          Hi Alan!

          Thanks for the reply. As mentioned in my first post I read through NT Help guide but I didnt understand it.

          1. What is meant with "fitted" regression line? I of course know what's a regression but not what the help guide means with "fitted".

          2. In the formula below the explanation: Where is the difference between "Total Trades" and "Summation of Trades" in the formula?

          Thanks!

          Comment


            #6
            Hello KirkHammett,

            Thank you for writing in.

            Both a Fitted Regression Line and the Coefficient of Determination formula are popular statistics concepts which you can find better/more in-depth explanation for with a web search, however I provided brief descriptions below.

            A fitted regression line on a graph represents of the mathematical regression equation for your data. Use fitted regression lines to illustrate the relationship between a predictor variable (x-scale) and a response variable (y-scale) and to evaluate whether the model fits your data.

            "Total Summation of Trades" is rSquaredSumOfXSq and "Summation of Trades ^2" is rSquaredSumOfX * rSquaredSumOfX. R Squared is the same as Coefficient of Determination, which I would suggest doing a web query for.

            Please let us know if you need further assistance.
            Alan P.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by dkbyond, Today, 06:43 PM
            0 responses
            3 views
            0 likes
            Last Post dkbyond
            by dkbyond
             
            Started by i2w8am9ii2, Today, 06:05 PM
            0 responses
            1 view
            0 likes
            Last Post i2w8am9ii2  
            Started by YevhenShynkarenko, Today, 05:46 PM
            0 responses
            4 views
            0 likes
            Last Post YevhenShynkarenko  
            Started by Bionian, Today, 04:14 PM
            0 responses
            3 views
            0 likes
            Last Post Bionian
            by Bionian
             
            Started by dkbyond, Today, 04:03 PM
            0 responses
            5 views
            0 likes
            Last Post dkbyond
            by dkbyond
             
            Working...
            X