Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Case Description

Preparation

In this exercise we will produce a cross section plot of relative vorticity through Hurricane Sandy. We will also create a more interesting layout which will include a geographic map showing the path of the cross section line.

...

It's probably easiest to prepare the cross section and the map separately, then bring them together at the end.

Steps

Plotting the Cross Section

Use a Cross Section View icon with a logarithmic scale vertical axis.The transect line should go from [50oN, 90oW] to  [30oN, 60oW], and the top pressure level we wish to display is 200hPa.

...

Use a Legend icon to move the legend to the right-hand side of the plot as shown. We may need to move this a little bit once we have the complete layout.

Plotting the Map

Use a Geographical View icon to define the map. The map area should be defined as being from [20oN, 110oW] to [70oN, 30oW] and should show the line of the cross section - use an Input Visualiser icon coupled with a Graph Plotting icon to achieve this. The location of New York City (40.71oN, 74oW) can also be added with another Input Visualiser icon coupled with a Symbol Plotting icon. The legend will look better if customised to use the Disjoint type.

A feature which will make the map overlay better with the cross section plot is to remove the labels from its left and bottom axes (via a Coastlines icon).

Putting it all together

These two plots can be combined by using a Display Window icon. Create one, edit it and create two views inside it. Drop your Geographic View icon into one and your Cross Section View into the other. Position them in a similar way as shown in the example plot. Once saved, this icon can be visualised and the final result created by dropping the various icons into the two views in the Display Window.

Creating a Macro

Create a macro from this plot by following this procedure.

...

Using a macro gives us an opportunity to improve the maintainability of the plot. In particular, we currently duplicate the coordinates of the cross section transect line - it is defined once in the Cross Section View icon and again in the Input Visualiser icon which is used to draw the line on the map. Put the coordinates of these points into variables at the top of the macro, then replace the two references to the line coordinates with these variables.

Extra Work

Try the following if you have time.

...