ACON
Home/Topics |
Commands |
More Examples
Aggregated Shading

/* read the data file */
Matrix_Read(cat(HostPath(),"Test Data/TestData.txt"),"data");
/* longitude latitude limits of plot */
Data_Window(-67,-62,41,44.0);
/* position on page of the axis border rectangle */
Data_Viewport(mm(20),mm(90),mm(190),mm(260));
/* use mercator projection */
Data_Projection("MERCATOR");
/* Aggregate the data into Total per 1 deg. squares */
aggdata = Aggregate(data[;1],1,data[;2],1,"TOTAL",data[;3]); // new syntax
aggdata[;1] -= 0.5; // move result to center of square
aggdata[;2] += 0.5;
/* grey level for each data level */
Data_Contour_Levels(10,0.75,20,0.5,25,0.2,30,0);
/* show the data as a shaded contour plot */
Shade_Rectangles(1,1,aggdata);
Outline_Rectangles(1,1,1,aggdata);
/* draw the data legend */
GreyScale_Legend(mm(92.00),mm(250.00));
/* draw a section of the Nova Scotia coastline */
Overlay_file(mappath("COAST1"));
Draw_Text(mm(22),mm(192),"Aggregated Shaded Rectangles");
/* draw axis, 1 deg labels, 0.5 deg tics, left and bottom edges */
Axis(1,1,0.5,0.5,1,0,1,0,0);
ACON
Home/Topics |
More Examples
|