converting tiff from ascii

4 visualizaciones (últimos 30 días)
Tanmoyee Bhattacharya
Tanmoyee Bhattacharya el 3 de Feb. de 2016
Editada: Image Analyst el 3 de Feb. de 2016
I have rainfall data in
lat lon Rainfall
34.67 87.56 79
34.68 87.56 90
Now I want to convert it in .tiff image format.How can I do this.

Respuestas (1)

Image Analyst
Image Analyst el 3 de Feb. de 2016
Editada: Image Analyst el 3 de Feb. de 2016
Loop over lat and lon and convert them into a row or column, then assign the value, maybe like
maxCols = ceil(max(100 * lon));
maxRows = ceil(max(100 * lat));
rainfallImage = zeros(maxRows, maxCols, 'uint8');
for k = 1 : length(lat)
col = round(100 * lon(k));
row = round(100 * lat(k));
rainfallImage(row, col) = Rainfall(k);
end
imshow(rainfallImage, []);
colormap(hot(256));
colorbar;
imwrite(rainfallImage, 'RainFallImage.tif');

Categorías

Más información sobre Images en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by