フィルターのクリア

2D plot to 3D Graph

3 ビュー (過去 30 日間)
Nicole Mezher
Nicole Mezher 2020 年 4 月 3 日
コメント済み: darova 2020 年 4 月 3 日
Hello, This is my 2D Plot and I can't figure out how to turn the Red curve into a 3D Plot or what the Z coordinate would even be for it. I would really appreciate some help. Here is my code for the red curve:
Receptive_Field = GME(s, sigE) - (0.5*GMI(s, sigI));
plot(s, Receptive_Field, 'r')
function E = GME(s,sigE)
E = exp(-1*(s.^2)/(2*sigE^2));
end
function I = GMI(s,sigI)
I = exp(-1*(s.^2)/(2*sigI^2));
end

採用された回答

darova
darova 2020 年 4 月 3 日
I made a simple example for you
x = 0:10;
y = sin(x)+2;
t = linspace(0,2*pi,30);
[T,Y] = meshgrid(t,y);
[~,X] = meshgrid(t,x);
[Z,Y] = pol2cart(T,Y);
surf(X,Y,Z,'facecolor','none')
line(x,y,'linewidth',3)
axis vis3d
Is this what are you looking for?
  6 件のコメント
Nicole Mezher
Nicole Mezher 2020 年 4 月 3 日
Yes
darova
darova 2020 年 4 月 3 日
Maybe another way. Here is my first script

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by