verde.load_surfer#
- verde.load_surfer(fname, dtype='float64')[source]#
Read data from a Surfer ASCII grid file.
This function reads a Surfer grid file, masks any NaNs in the data, and outputs a
xarray.DataArraythat contains easting and northing coordinates, data values, and associated file metadata.Surfer is a contouring, griding and surface mapping software from GoldenSoftware. The names and logos for Surfer and Golden Software are registered trademarks of Golden Software, Inc.
http://www.goldensoftware.com/products/surfer
- Parameters:
- fname
stror file-likeobject Name or path of the Surfer grid file or an open file (or file-like) object.
- dtype
strornumpy.dtype The type of variable used for the data. Default is
float64. Usefloat32if the data are large and precision is not an issue.
- fname
- Returns:
- data
xarray.DataArray A 2D grid with the data.
- data