[Met_help] viewing/plotting data from Prepbufr files

John Halley Gotway johnhg at rap.ucar.edu
Thu Jun 26 09:20:07 MDT 2008


Luke,

Looks like this utility isn't compatible with METv1.0.  To specific, we generalized the plotting routine calls so that they could handle the path to where the font data is located.  For all of those 
function calls, just removing the last argument (the path to the data) might work.  Then it'll just look in the default place.  But there might be other compatibility issues - I'm really not sure.

So you could try tinkering with the code to make it work with METv1.0, or, what would be easier, you're welcome to play around with a beta version of METv1.1 which should be compatible with this utility.

If you'd like to, you can access that beta version at ftp.rap.ucar.edu/incoming/irap/johnhg/METv1.1beta6.20080613.tar.gz.

The downside though is that we haven't updated the documentation for this version.  We're working on that.  METv1.1 is just about finished other than the documentation.

John

Luke Peffers wrote:
> John, here is my attempt to build with pb2nc_var_plot (build error below).
> If you see anything obvious that you are able to point out, that would be
> fine.  Otherwise, please don't trouble yourself with this.  I don't want you
> to trouble yourself with this...you've already done too much!
> 
> 
> On Wed, Jun 25, 2008 *** Making pb2nc_var_plot application ***
> 
> 
> g++ -o pb2nc_var_plot pb2nc_var_plot.cc \
>   -DMET_BASE=\"/fuelberg/r0/lpeffers/MET_9/METv1.0\" \
> -I../../lib -I/opt/local/include  -I/fuelberg/r0/lpeffers/MET_9/GSL/gsl-1.9
> -I/fuelberg/r0/lpeffers/MET_9/GSL/gsl-1.9/cdf
> -I/fuelberg/r0/lpeffers/MET_9/GSL/gsl-1.9/gsl \
> -L../../lib -L/opt/local/lib -L/fuelberg/r0/lpeffers/MET_9/GSL/gsl-1.9/lib
> \
> -lvx_met_util -lvx_analysis_util -lvx_wrfdata -lvx_met_util \
>         -lvx_contable -lvx_grib_classes \
> -lvx_econfig -lvx_gsl_prob -lgsl \
> -lvx_plot_util  -lvx_render -lvx_pxm -lvx_color -lvx_ps -lvx_afm \
> -lvx_data_grids -lvx_gnomon -lvx_nav -lvx_cal -lvx_util -lvx_math -lm \
> -lnetcdf_c++ -lnetcdf \
> 
> pb2nc_var_plot.cc: In function `int main(int, char**)':
> pb2nc_var_plot.cc:225: error: no matching function for call to
> `PSfile::choose_font(int, double, char[512])'
> ../../lib/vx_ps/vx_ps.h:105: note: candidates are: virtual void
> PSfile::choose_font(int, double)
> pb2nc_var_plot.cc: In function `void draw_map(PSfile&, BoundingBox&)':
> pb2nc_var_plot.cc:328: error: no matching function for call to
> `draw_world(Grid&, BoundingBox&, PSfile&, BoundingBox&, BoundingBox&, const
> Color&, char[512])'
> ../../lib/vx_plot_util/vx_plot_util.h:112: note: candidates are: void
> draw_world(const Grid&, const BoundingBox&, PSfile&, const BoundingBox&,
> const BoundingBox&, Color)
> ../../lib/vx_plot_util/vx_plot_util.h:114: note:                 void
> draw_world(const Grid&, PSfile&, const BoundingBox&, const BoundingBox&,
> Color)
> pb2nc_var_plot.cc:329: error: no matching function for call to
> `draw_states(Grid&, BoundingBox&, PSfile&, BoundingBox&, BoundingBox&, const
> Color&, char[512])'
> ../../lib/vx_plot_util/vx_plot_util.h:92: note: candidates are: void
> draw_states(const Grid&, const BoundingBox&, PSfile&, const BoundingBox&,
> const BoundingBox&, Color)
> ../../lib/vx_plot_util/vx_plot_util.h:94: note:                 void
> draw_states(const Grid&, PSfile&, const BoundingBox&, const BoundingBox&,
> Color)
> make[3]: *** [pb2nc_var_plot] Error 1
> make[2]: *** [all] Error 2
> make[1]: *** [targets] Error 2
> make: *** [all] Error 2
> lpeffers pts/1 :0.0 logged on
> 
> Luke Peffers
> FSU Meteorology
> 
> 
> at 9:16 PM, John Halley Gotway <johnhg at rap.ucar.edu> wrote:
> 
>> Luke,
>>
>> The utility is named "pb2nc_var_plot".  You can try to insert it into your
>> version of MET and rebuild.
>>
>> The attached tar file contains 3 files:
>> - a top-level MET Makefile.  Look in it to see the lines I added relating
>> to "PB2NC_VAR_PLOT", and modify your version of the top-level Makefile
>> accordingly.
>> - Put the src/pb2nc_var_plot directory into the src/ directory of MET.
>> - Try rebuilding MET and building this tool with it.
>>
>> Let me know if you run into any problems.  And be aware that the Makefiles
>> included are the "latest" development version.  They may not be completely
>> compatible with the version of the code you have.  So you may need to tinker
>> with them some.
>>
>> Good luck.
>>
>> John
>>
>>
>> Luke Peffers wrote:
>>
>>> Sure John, some code that I could tinker with would be great.  I think it
>>> will help me!
>>>
>>> Thanks
>>>
>>> Luke
>>>
>>> On Wed, Jun 25, 2008 at 3:58 PM, John Halley Gotway <johnhg at rap.ucar.edu>
>>> wrote:
>>>
>>>  Luke,
>>>> I have a small utility I use for plotting the locations of the PREPBUFR
>>>> observations, but it reads the NetCDF output of PB2NC rather than the
>>>> PREPBUFR files directly.
>>>>
>>>> It creates a PostScript plot with the world outlines on it and red dots
>>>> where there are observations.  You can select the observation variable
>>>> type(s) to be plotted with the "-var" command line option and message
>>>> type(s) to be plotted with the "-typ" command line option.  Also, you can
>>>> specify some arguments to zoom the plot up to a particular region of the
>>>> world.  By default, it plots the lat/lon location for all variables and
>>>> message types on the whole earth.
>>>>
>>>> If you think it'd be useful, I'd be happy to provide it to you.  But
>>>> since
>>>> I'm pretty busy these days, I wouldn't be able to provide much support
>>>> for
>>>> it.
>>>>
>>>> I'm not aware of tools that plot PrepBufr locations directly, but it
>>>> might
>>>> be worth searching for that yourself.
>>>>
>>>> Just let me know.
>>>>
>>>> John Halley-Gotway
>>>>
>>>> Luke Peffers wrote:
>>>>
>>>>  Hello, I would like to know if there is a tool that can plot data from
>>>>> the
>>>>> PREPBUFR files, which I am using with MET.
>>>>>
>>>>> Thank you
>>>>>
>>>>> Luke Peffers
>>>>> FSU Meteorology
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------
>>>>>
>>>>> _______________________________________________
>>>>> Met_help mailing list
>>>>> Met_help at mailman.ucar.edu
>>>>> http://mailman.ucar.edu/mailman/listinfo/met_help
>>>>>
>>>>>
> 


More information about the Met_help mailing list