Recently I got some gridded data to visualize on a map. However, I found that the array storing the gridded data cannot be shown normally on the map. The first column and bottom row are ignored when plotted on the map. I wrote a demo to show the problem. ;This is a test code; data=[[1,15,48,1],[45,34,38,34],[78,1,25,13],[34,21,36,57]] ;Plot the map; m = MAP('Geographic',limit=[0,-10,20,10]) m.mapgrid.LABEL_POSITION = 0 m.mapgrid.LINESTYLE = '-.' m.mapgrid.GRID_LATITUDE = 5 m.mapgrid.GRID_LONGITUDE = 5 m.mapgrid.FONT_SIZE = 6 m['Latitudes'].LABEL_ANGLE = 0 m['Longitudes'].LABEL_ANGLE = 0 ;Visulize the array; im = IMAGE(data, IMAGE_DIMENSIONS=[20,20], IMAGE_LOCATION=[-10,0], grid_units='degrees', transparency=30, rgb_table=13, order=1, margin=0, POSITION=[0.1,0.1,0.75,0.75], overplot=m) continent = MAPCONTINENTS() c = COLORBAR(target=im,/BORDER,orientation=1,TEXTPOS=1,position=[0.7,0.1,0.73,0.75],TITLE='data (unit)') c.FONT_SIZE = 6 In theory, the 4*4 grids should be shown with a spatial resolution of 5 deg from lon: -10, lat: 0. However, the plotted result just showed 3*3 grids, with the first column and bottom row not shown in the plot. Could someone help with this problem? Thanks!!
|