How can I plot in 3D with three different size vector?
4 次查看(过去 30 天)
显示 更早的评论
Actually I have
a=[-2 -1.5 -1 0 1 1.5 2];
b=1:16368;
c=1:16368;
I used plot3 and stem3 but it requires vector of equal length. How can I do this? Please give me any suggestion.
回答(1 个)
Luuk van Oosten
2014-11-17
Another option is scatter3;
try use
scatter3(a,b,c)
But you already gave the answer yourself;you require vectors of equal length. Try:
length(a)
this will return 7.
length(b)
and
length(c)
both return 16368.
you could try to make 'b' and 'c' using linspace;
b = linspace(1,16368,7)
checkcheck: length(b)=7.
On the other hand, I have no idea what you are trying to do, so maybe you could specify your problem a bit more.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Annotations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!