Borrar filtros
Borrar filtros

Change interval values of lat and lon

6 visualizaciones (últimos 30 días)
Brendan Clark
Brendan Clark el 15 de Mzo. de 2021
Comentada: Brendan Clark el 15 de Mzo. de 2021
I am using pcolor to plot geographic data. Doing pcolor(double(Lon),double(Lat),X) displays values of longitude as 0, 50, 100, 150 etc and latitude as 0, 20, 40, 60 etc. How can I change the values of lat and lon displayed so they are in intervals of 30 for longitude (instead of 50) and 15 for latitude (instead of 20)? Will the grid lines also change?
  2 comentarios
DGM
DGM el 15 de Mzo. de 2021
Ticks and labels are axes properties. You can get a list of what the current settings are by running
get(gca);
You can see what options are are available for these properties by running
set(gca);
For tick locations, you can set them to whatever you want. For example:
set(gca,'xtick',[30 60 90 120],'ytick',[15 30 45 60]);
Brendan Clark
Brendan Clark el 15 de Mzo. de 2021
Thank you!

Iniciar sesión para comentar.

Respuestas (1)

Cris LaPierre
Cris LaPierre el 15 de Mzo. de 2021
Use the functions xticks and yticks.

Categorías

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