How to fit/scale a big data set into a smaller one?
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi,
my problem is pretty similiar to this one:
https://de.mathworks.com/matlabcentral/answers/222218-how-to-scale-a-dataset-to-fit-an-other-dataset
except that I dont have a repeating signal.
My problems is rather looking like this one:
![2Datasets.png](https://www.mathworks.com/matlabcentral/answers/uploaded_files/226021/2Datasets.png)
DataSet 1 is the blue plot, defined by 65 X and Y values. DataSet 2 is the yellow one, defined by 3 values. Now my goal is to move, turn, scale etc. the blue data points in a way, so they fit the yellow points in the best possible way. Only limitations are a intersection with zero and the ratio between the blue data must stay equal. I tried several approaches with least square error or lsqcurvefit but the problem is always the difference in the number of values between the 2 data sets. A 9th degree polynomial fit of the blue data comes pretty close to what it looks like.
I also thought of the optimization toolbox, but I am failing to use it in the right way.
Cheers!
Paul
1 commentaire
dpb
le 23 Juin 2019
No idea what you intend as a result. What does the phrase "limitations are a intersection with zero and the ratio between the blue data must stay equal" possibly mean?
Only thing I can suggest would be to draw onto the graph another set of points that represent what you think the ideal answer would look like...maybe that could let somebody visualize the request.
Réponses (0)
Voir également
Catégories
En savoir plus sur Solver Outputs and Iterative Display dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!