I have found an 9th-degree that matches very well. Worst fit is off by 0.4, which is within my margin of error. I have a feeling I can get a match that is just as good using methods that require less CPU-cycles, but speed is not an issue (within reason).
I simply want to use the equation to find the avg height given an age between 4 and 17. I don't want to store the data itself, since the age can be float. (What do we call float in math again? The reals?) I have the "end points" on every data-set, so I don't need to extrapolate anything.
I'm not sure where you are located, but where I am from (Norway) doctors use something we call "Percentile Charts" (loosely translated) to track the development of children. The charts have data for length, weight, circumference of head and so on, and quickly tells the doctor what percentile the kid is in. I know many countries use these.
An example chart:
http://www.cdc.gov/nchs/data/nhanes/growthcharts/set1clinical/cj41l020.pdf
You can find more of them here:
http://kidshealth.org/parent/growth/growth/growth_charts.html
If you look carefully at them, you can see that IE, the line for the 75th percentile is not parallel, perpendicular or even equidistant in both directions from the 50th percentile. So, I need all the data on every single "percentile-line", from every chart in every category.
Now, if I want a better "resolution" than year by year, that is quite a lot of data points to store, seeing as I have to make this in javascript. So, rather than fill a file with endless arrays and work from those, I want to model the data.
You punch in 11.5 kg and 80 cm for a girl, and the program tells you that this is in the 85th percentile by plugging the numbers into the appropriate equation. I don't need to accept data that would be outside the percentile charts, so I never have to worry about extrapolation.
Now, I CAN do this by using something like CurveExpert, as you suggested. But, while working on this I have come to find the concept of curve-fitting to be very intriguing, so I want to know what I am doing. I want to learn how to fit a polynomial to a set of data. I don't expect to get better results than a program does by doing it myself, but I want to understand the process and be able to do it myself.
This became a lot longer than I intended.
k
That's about as much information as I can give :)