Interpolation problem with interp2
10 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
D.
el 27 de Mayo de 2011
Comentada: Walter Roberson
el 13 de Oct. de 2016
Hi everyone!
I did some computations on a grayscale picture and I would like to interpolate some points in my matrix. My problem is that interp2 doesn't allow to do what I want to.
Let's say my matrix is im
im = [1 2 3; 4 nan 6; 7 8 9];
and when I do:
[colum row] = meshgrid(1:3,1:3);
colum_i = 2;
row_i = 2;
zi = interp2(colum, row, im, colum_i, row_i);
I would like that it interpoles the nan. Is there a way to redefine a point in the matrix instead of a point between the points of the matrix?
My picture is a 512x512 pixels and interp2 would be very useful and fast instead of computing for every point separately...
Thank you for yours answers.
Regards, D.
0 comentarios
Respuesta aceptada
Walter Roberson
el 27 de Mayo de 2011
1 comentario
Jan
el 27 de Mayo de 2011
Walter, you are typing faster than me - yesterday, today and tomorrow. It would increase the efficiency of my work, if a small icon appears in the question to show, that you are reading it currently - and will have answered it some seconds later.
Más respuestas (2)
Jan
el 27 de Mayo de 2011
2 comentarios
jothi lakshmi maniyan
el 13 de Oct. de 2016
hi i need bicubic interpolation matlab code fully pl help
Walter Roberson
el 13 de Oct. de 2016
https://www.mathworks.com/matlabcentral/fileexchange/20342-image-interpolation--ba-interp2-
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!