A question about scatteredInterpolant function
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
BN
el 27 de Abr. de 2020
Hello everyone,
I have a question about interpolating function scatteredInterpolant .
Assuming I have some scattered points; then I used scattered interpolant to having a 0.5x0.5 grid data from these.
Now I have data for each 0.5 x 0.5 grids (when ndgrids that I used in this process represents the center of each grid)
I want to know the value that interpolated at the center of each grid represents the average? or sum? of data for this 0.5x0.5 grid based on the values of my scattered data or just the value in the center of this 0.5x0.5 grid and not representative of a 0.5x0.5 grid ?
Please let me know if any more clarification required.
Thank you so much
0 comentarios
Respuesta aceptada
Walter Roberson
el 27 de Abr. de 2020
Interpolation does not attempt to be "representative" in any way of the values.
You can choose from different interpolation methods. The default interpolation method triangulates the data, and then for each point that sampling is requested at, the method finds the vertices of the triangle that the point is within, and does linear interpolation of the values at the vertices based upon the distances to the vertices.
To emphasize: if you were in the middle of a huge peak in your data, but within that peak there was a very narrow deep pinprick, and you just happened to sample right within that pinprick, then the interpolation would not pay any attention to the values of the huge peak dominating that region, and would care only about the values at the vertices the point is at.
3 comentarios
Walter Roberson
el 27 de Abr. de 2020
In some cases you might want to interpolate at a finer grid, and then resample to a less fine grid, such as by doing fft2() then ifft2() with a smaller number of output points, or by doing blockproc() to calculate the mean of blocks, or by using conv2() to calculate moving means but then extracting only some values from that.
Más respuestas (0)
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!