How can I plot various vectors together with surf or mesh when they have different x, y and z values?
显示 更早的评论
Hello,
assuming I have 4 times of these two vectors
G=[-1 2 5 -3 3 4] %(x)
P=[36 45 23 54 56 23] %(y)
G=[2 -3 5 -3 3 1]
P=[46 23 45 79 23 12]
G=[2 2 -3 2 3 -1]
P=[36 45 23 54 56 23]
G=[-1 -4 -4 -3 3 2]
P=[36 37 14 54 56 56]
each and every pair gives you a plot if you just do plot(G,P)
What I want to do is plot them on a mesh or surf so that X axis will have the P values Y axis will have the G values for each P and the Z axis will just be a number from 1:4 or as many the plots are.
my thoughts up to now come to interpolation in order to fix all the P values somehow , but I really do not know how to do it.
Any suggestions?
/Andreas T.
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Surface and Mesh Plots 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
