On 10/30/10 3:41 AM, John wrote: > I've searched through the netcdf4-python trunk, but I find no > reference of NetCDFFile as in how the basemap or Scientific.IO.NetCDF > modules use it. > > For compatibility with my old scripts, is it safe to simply: > > from netCDF4 import Dataset as NetCDFFile > > ?? > > Thanks, > john > John: Neither basemap or Scientific.IO.NetCDF uses it. What gave you the impression they did? There is a 'NetCDFFile' in function in basemap, but it is based on the pure-python netCDF module pupynere. It doesn't support netcdf-4 and I only recommend using it for the occasional light use.
The netcdf4-python API is mostly compatible with Scientific.IO.NetCDF, so if you have old script that use the latter, you can try: from netCDF4 import Dataset as NetCDFFile The docs for netcdf4-python are at http://netcdf4-python.googlecode.com/svn/trunk/docs/netCDF4-module.html -Jeff ------------------------------------------------------------------------------ Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users