How do I smooth a curve on a surf plot?
3 ビュー (過去 30 日間)
古いコメントを表示
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/933464/image.jpeg)
I have been trying to "smooth" out this curve in MATLAB but have been unable to. The goal is to have a smoother curve depicted in this surf plot. Any ideas?
I have attached the code needed to make the figure to and I used the code below to generate this figure
surf(ZFF_vals, DFF_vals, Fin
0 件のコメント
回答 (2 件)
Sulaymon Eshkabilov
2022 年 3 月 20 日
You can try smoothdata() with Gaussian, e.g.:
X = load('DFF_vals.mat');
Y = load('ZFF_vals.mat');
Z = load('Fin.mat');
Zsmooth = smoothdata(Z, 'gaussian', 25);
subplot(211)
mesh(X,Y,Z)
subplot(212)
mesh(X,Y, Zsmooth), view([30, 45, 30])
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!