Azzera filtri
Azzera filtri

Should I modify x-values for curve fitting with response variable?

8 visualizzazioni (ultimi 30 giorni)
I am trying to fit concentration (in x-axis) and approach rate (in y-axis) using a logistic equation. The real values of x are [0.5, 2, 5, 9]. Should I fit real_x vs y? I think I saw somewhere that one should use equidistant points (like x = [1,2,3,4]) for fitting. What is your opinion?

Risposta accettata

Matt J
Matt J il 31 Mag 2024
Modificato: Matt J il 31 Mag 2024
Matlab's fitting solvers do not require the x data to be equidistant.
I'm not sure why it would be a matter of opinion, though. Since you do not have equidistant x, what choice do you have but to use the non-equidistant ones?
  3 Commenti
Matt J
Matt J il 31 Mag 2024
You are quite welcome, but please Accept-click the answer if your question has been resolved.
John D'Errico
John D'Errico il 31 Mag 2024
+1 of course, but I would add that spacing/placement can be a significant factor.
For example, given a tight cluster of points, and one point out in the weeds. Now that one point on the edge of tomorrow will often have a high influence on the result.
Another case is the simple one where you have points at exactly 2 levels, with multiple replicates. In this extreme case of a non-uniform sampling, you really only have 2 pieces of information, and a linear fit would pass through the average of the two clusters. This even applies to a case where you have two very tight clusters of points. Again, you have essentially only two pieces of information due to the non-uniform sampling.
All of this gets into things like influence matrices, the hat matrix, and an entire course or book on the subject.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Get Started with Curve Fitting Toolbox in Help Center e File Exchange

Prodotti


Release

R2024a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by