Problem with Interpolation - Scattered Data away from initial points.

1 次查看(过去 30 天)
Hello quys! I want to make interpolation of scattered data (x,y,z). I also plot these points (x,y,z). The matlab code is the following:
Interp_z=scatteredInterpolant(x,y,z);
figure
[qx,qy] = meshgrid(y_start:intervals_y:y_stop,x_start:intervals_x:x_stop);
qz = Interp_z(qx,qy);
mesh(qx,qy,qz);
axis([y_start y_stop x_start x_stop z_start z_stop])
hold on;
plot3(x,y,z,'o');
The problem is that the 3D surface that is created and plotted is away from points (x,y,z). (see picture attached) Could anyone please help me, to find a solution? Any help will be highly appreciated!

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Interpolation 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by