Plotting several 2d plots on a 3d axis.
11 ビュー (過去 30 日間)
古いコメントを表示
So I have a particular parameter which I'm interested in what happens for different values of it:
w = 0:0.1:1;
Then I compute a value, I, which changes over time for each particular value of w, i.e., I = I(n,t) where t is the index for the time and n is the index for the particular w value I want.
Now, I want to make a plot for how I changes for each variable, w and time. I have that size(w)=11 and size(time)=2001 so that I is a matrix of size 11x2001.
I've tried using surf but can't see much in it.
I would like to know how to create a 3D plot of individual 2D plots, so that it looks like graphs of I (in z), varying with time (in y) but then repeated for each distant value of w in a sort-of fake x-axis. Something like what's attached.


Any ideas? Thank you in advance!
0 件のコメント
回答 (1 件)
KSSV
2017 年 6 月 8 日
N = 25 ;
[X,Y,Z] = peaks(N) ;
%%ribbon plot
ribbon(Y,Z) ;
figure
hold on
for i = 1:N
plot3(X(i,:),i+ones(N,1),Z(i,:))
end
view(3)
0 件のコメント
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!