Create a surface from several 1D plots
Afficher commentaires plus anciens
I have fitted several groups of scattered points (x,z) into 1D plots which vary on a third variable y. I now want to connect these discrete points in a 3D plot with the third axis being y. How would I go about doing this? I tried using the surf function but I need my y variable to be a matrix so I'm confused because for each entry in y (vector) a fitted (x,z) plot is created, so how could y be a matrix?
Apologies if I posed the question poorly and thank you.

Réponse acceptée
Plus de réponses (1)
KSSV
le 8 Sep 2021
0 votes
- See to it that all the curves have same dimensions. If not use interp1 and get them into same size.
- Initliaze matrices X, Y, Z with rows as number of curves and columns as number of points in each curve.
- Use surf on X, Y, Z.
Catégories
En savoir plus sur Surface and Mesh Plots dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

