I'm looking for a way to derive the equation of a curve that will fit a set of points.
I have a set of points like this:
{130,20},
{150,30},
{160,40},
{165,50},
{175,60},
{185,70},
{192,80},
{200,90},
{205,100},
{210,120},
{215,140}
How can I programmatically derive a formula for this curve? I'm writing software that will have different data for the X values but all data will follow the general shape of the curve.
For more background information, I'm estimating Training Stress Score (Y values) from heart rate (x values). More information on that here: https://www.trainingpeaks.com/blog/estimating-training-stress-score-tss/.
So given a heart rate of 170, it would return a value of 50. However, this should be able to be made more accurate with a curve since a heart rate of 174 should have a TSS value of closer to 60 than 50.
Since I'll be allowing a user to define their own heart rate values (depending on their own personal heart rate zones), the method of finding the curve will need to be derived from those values.