Borrar filtros
Borrar filtros

How to rotate a map?

8 visualizaciones (últimos 30 días)
HADJ MOHAMMED
HADJ MOHAMMED el 8 de Nov. de 2023
Comentada: Dyuman Joshi el 9 de Nov. de 2023
I have SST data in .nc format and I proceeded with this script
ncinfo('filename')
ncdisp('filename')
variable_name=ncread('filenema','variable_name')
[laty, lonx] = meshgrid (lat,lon)
mean_sst = mean(analysed_sst,3)
imagesc(lon,lat,mean_sst)
and I got this result but the map of South Korea is rotated, what can be the problem?
  1 comentario
Dyuman Joshi
Dyuman Joshi el 8 de Nov. de 2023
In the high-level version of the imagesc(), the direction of y-axis is reversed (along with some other changes), as can observed from the figure as well.
Another method to revert it back, aside from Chunru's answer below, is change the y-direction property to normal -
ax = gca;
ax.YDir = 'normal';

Iniciar sesión para comentar.

Respuestas (1)

Chunru
Chunru el 8 de Nov. de 2023
It is upside down. Add the following:
axis xy
  2 comentarios
HADJ MOHAMMED
HADJ MOHAMMED el 9 de Nov. de 2023
where I add it Please? because it didn't change
Dyuman Joshi
Dyuman Joshi el 9 de Nov. de 2023
Add it after the imagesc() call

Iniciar sesión para comentar.

Categorías

Más información sobre Scatter Plots 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