Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Linear regression of data that is not Series data

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

    Linear regression of data that is not Series data

    Hello,

    I would like to do a linear regression plot & r-squared calculation of a collection of 5 or so data points I gathered (each an x,y as in time, price).

    Unfortunately, the occurrence of these points is not aligned with any regularity in comparison to the Series data of the chart. In other words, the x's are at somewhat random intervals.

    Would you have any suggested approaches that involve NT8 indicator scripts, or is it better to write out the linear regression calculations by hand?

    Thank you,

    #2
    Hi,

    for the r-squared part it would be worth a shot to use the same algorithm like in the RSquared indicator, replace barIndex with index and Period with N.

    Comment


      #3
      Hey, thanks - the R-Squared indicator is certainly a great launch point for this, as are the other related functions.

      I keep forgetting there are actual scripts available for these built-in functions that I can copy and modify as appropriate!

      Appreciate the help.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      581 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      338 views
      1 like
      Last Post Geovanny Suaza  
      Started by Mindset, 02-09-2026, 11:44 AM
      0 responses
      103 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by Geovanny Suaza, 02-02-2026, 12:30 PM
      0 responses
      554 views
      1 like
      Last Post Geovanny Suaza  
      Started by RFrosty, 01-28-2026, 06:49 PM
      0 responses
      552 views
      1 like
      Last Post RFrosty
      by RFrosty
       
      Working...
      X