Saturday, January 30, 2021

Introduction to using GRIB files with XyGrib

A key aspect of modern weather work is the use of numerical weather model forecasts in Grib format. This should not be treated as a sole source of information, but it is extremely valuable once you have evaluated the forecast. Methods of doing that, along with an overview of models and available weather are covered in Background on GRIB Files and Numerical Weather Forecasts.

Here we jump straight into the process by looking at a couple options for downloading and viewing the files.


We start with XyGrib because it is a free, easy to use Grib Viewer app that has both PC and Mac versions. It also has the advantage of providing very convenient GRIB file selection and download from right within the app, including a wide range of models, and several unique European sources. 

Get the app from in the  Downloads section. Choose the online installer for Mac or PC.  Install in the normal manner, and open the app.  For the Mac install, you will need to open System Preferences / Security and give the app permission to be installed. During the installation process, be sure to check the option to install high-resolution maps. We need these for regional forecast work. Here is a short video on getting started. We will later add some with more details.

A review of the steps to download a file and  a couple tips

Step 1. Default location of downloaded Grib files on a PC will be c:/users/username/xygrib/grib. This is similar in the Mac, but it is a hidden file, namely /.xygrib/grib. To see the contents of either one, use the folder icon in the menu bar, next to the quit button. The contents can be edited from within that window, or separate folders could be set up for different voyages or projects.

Step 2. Draw a box with the cross-hair tool in the main menu icon, then press the globe icon to select a model and other options, and download. 

Step 3. After downloading, confirm the file storage location, which will display the data. If not already showing on the left, turn on the View Data panel  ctrl+V (PC) or cmd +V (Mac). As you move the cursor over the map you will see the values showing in the panel. You can pull the panel off to the side. Once taken out, get it back in by restarting the program.

 XyGrib Start up tips

• In the window selection of window position, N and E are +, amd S and W are – numbers. 

• On the menu/Weather map the top parts are closing what uses color overlay, and that overlay covers land and water.  For inland work, maybe save that color for REFC or rain 

• For a bigger view of time and date, click the slider bar at the bottom

Note: the menu /File/New instance creates a new window of the program duplicating what was in the last instance. This can be valuable in some circumstances, ie for comparing different  models or times  side by side, but troublesome in others if you forget more than one is open.

• To update a file, use ctrl+d or cmd+d (Mac). This will fetch the existing file area and the same info that was left in the set up window. Note it will give the file marked with the UTC of the download time, but you will not know from the name if the file is same or different data for the region.

•  In menu Options/Units: set speeds to kts and coordinates to ddÂș' (note use of European comma for a decimal point.) One arc minute (1.0') is one nautical mile, so we can think through the extent of 12.2' more easily than 12' 24".)

• To see true GRIB file resolution, use menu/Weather Map/Weather Options/Wind arrows on GRIB grid, then zoom in to see where actual data points are located. You can then measure the distance between grid points (tips of the wind arrows) with the the tool from menu/Earth/Great Circle Distance. Then shut this off when done. The true grid point display is awkward for  normal use, so it then can be shut off for a scaled interpolation display.

• Caution, when you include higher altitude data, such as 500 mb or 850 mb surface, you do not get to choose parameters, so you are enhancing file size. There are several that get loaded: height, wind speed (the two main ones we need) plus you get RH, air temp, and theta-e temp, which is not a parameter we use in our weather course—it is a measure of stability, but we now have forecasts of simulated weather radar (composite reflectivity, REFC) which is a much easier and dependable way to forecast squalls.

• Models not yet in XyGrib but expected in the next build are HRRR (regional US weather) and RTOFS (global ocean currents and SST).

• The NAM CONUS available in XyGrib is only 12 km, not the 2.5 km version that would be preferred for regional route optimization. XyGrib does have the Arome data at 2.75 km that can be used for practice in Europe. The HRRR when available is 3 km which will serve US needs for regional work.  (Note that the challenge the programmers face here is offering the hi-res data can overwhelm your delivery system if the user is not careful. Saildocs also limits NAM to 12 km.  File size goes up as the square of the resolution.)

• Practice using right click on a data set to create a Meteotable of the data, which is similar to the meteogram seen in other programs.

• Practice downloading computed skew-T data from GFS model. We discuss these diagrams in our textbook, but we do not include them in our online weather course. This is a nice feature of XyGrib. Expedition is the only other grib viewer app I know of that includes these. Not many mariners use these underway, because we have the forecasts that are based on these, but they do provide a picture of the vertical structure of the atmosphere. 

We have a playlist of videos on this type of diagram, but there are many more, and many live sources online including those with real data. Soundings are measured at 00z and 12z, and their input to the models generally makes the analyses and forecasts made at those times somewhat better than the 06 and 18z data.

No comments: