
interpolation of 3d data
16 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I want to interpolate my data with respect to z values means the blank spaces present got filled and z values are interpolated by krigging technique and get result in x y z format but the codes present on the forum interpolates data in the form of bigger matrix and and also do not provide satisfactory results. some code also fails and returns error as data size is too large.
Can anybody pls suggest a code for this. Pls help.....
0 comentarios
Respuestas (1)
KSSV
el 18 de Abr. de 2019
Editada: KSSV
el 18 de Abr. de 2019
data = importdata('slice1_grid1.txt') ;
x = data(:,1) ;
y = data(:,2) ;
z = data(:,3) ;
%% Make grid
m = 5000 ; n = 5000 ;
xi = linspace(min(x),max(x),m) ;
yi = linspace(min(y),max(y),n) ;
[X,Y] = meshgrid(xi,yi) ;
Z = griddata(x,y,z,X,Y) ;
pcolor(X,Y,Z)
shading interp

2 comentarios
Walter Roberson
el 21 de Abr. de 2019
output = [X(:), Y(:), Z(:)];
csvwrite('interpolated_slice.csv', output);
Ver también
Categorías
Más información sobre Interpolation en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!