Follow

How can I grid only the area inside my data limits using Surfer?

You can constrain the gridded area (and hence the contours) to the area inside the convex hull of the data by choosing to blank the grid outside the convex hull of the data during the gridding process. You can use this option in the user interface and via automation in a script.

In the user interface, click Home | Grid Data | Grid Data, select the data file and click Open. In the Grid Data dialog, check the box “Blank grid outside convex hull of data”. This automatically blanks the area outside the convex hull of the data points.  

Surfer's Grid Data dialog where all gridding parameters can be customzed

If you are using a script in Surfer 13 or higher, you could use the .BlankOutsideHull parameter of the GridData3 method:

 

    SurferApp.GridData3(DataFile:=SurferApp.Path + "\samples\Demogrid.dat", BlankOutsideHull:=True, InflateHull:=-1, OutGrid:="c:\temp\Demo3.grd")

 


 

If you are using Surfer 10 or previous, or you are using a script in Surfer 11 or 12, you can blank the areas outside the convex hull of the data using one of these methods:

1.  Use a different gridding method. 

Use a different gridding method that does not create data in areas where there was no data to begin with (i.e. Triangulation with Linear Interpolation or Natural Neighbor). The area outside the convex hull of the data will be automatically blanked.

2.  Grid your data twice and use Grid Math.

If you prefer to grid with a different method like Kriging, but want it blanked as if it were gridded with Triangulation with Linear Interpolation,  grid the data with both methods and then click Grid | Math to combine them. Use the formula A + B - B, where A is the Kriging GRD and B is the Triangulation GRD. The output GRD will be blanked where blanked in the Triangulation grid, and have the Kriging grid values in the non-blanked areas. This would also give you data only inside the convex hull of the data.

If you wish to constrain the gridding inside an even tighter boundary around your data than the convex hull, you can use one of these methods:

1.  Blank the grid outside the data limits.

Grid your data as normal by clicking Home | Grid Data | Grid Data, select the data file and click Open, specify any gridding parameters you wish and click OK (it will be a rectangular grid). Create a BLN boundary file defining the outline of your data points. After the BLN file is created, click Grids | Edit | Blank, select the grid file and click Open, select the BLN file and click Open, and save the blanked grid to a new name.  Create maps from the blanked grid file.  This can create maps with data inside any boundary, so it would a good option to choose if you want the limits tighter than the convex hull of the data.

To create a BLN file, please see: How can I create a BLN file in Surfer? Or, if you have our MapViewer or Didger software packages, you can easily do this by importing your data points, selecting them and using the Convex Hull command to create a polygon of the convex hull around the data points, and then click File | Export to export the polygon to a BLN file.

 2.  Use a fault file to define your data limits.

Create a BLN boundary file that defines the outline of your data points and use it as a fault file during gridding. Click Home | Grid Data | Grid Data, select your data file and click Open. In the Grid Data dialog box, click on the Advanced Options button, click the Breaklines and Faults tab, and specify the BLN as a fault file. Only some gridding methods support faults. Kriging does not, but Minimum Curvature (very similar to Kriging) does.

 

3.  Grid the data and specify a reduced search radius. 

Click Home | Grid Data | Grid Data, select your file and click Open. In the Grid Data dialog, click on the Advanced Options button, then click on the Search tab. Remove the check mark from the No Search (use all of the data) if necessary, and specify the Radius 1 and Radius 2 values.

The default Kriging method offers the Search option. Other methods that offer it include Inverse Distance, Modified Shepard's Method, Nearest Neighbor, Radial Basis, Moving Average, Data Metrics, andLocal Polynomial.

Some gridding methods do not have this option, including Minimum Curvature, Natural Neighbor, Polynomial Regression, and Triangulation with Linear Interpolation.

 

Related articles: How can I create a map inside an irregular boundary in Surfer?

 

Updated January 30, 2017

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.