You can constrain the gridded area (or contours) to the area inside the data area in Surfer. This article covers all the methods available to restrict the 2D or 3D grid results to the data limits during gridding in Surfer. If you are interested in the options available to do this after the grid has been created, see Create an irregular-shaped map in Surfer.
The following topics are covered in this article:
- Assign NoData outside the convex hull of data
- Assign NoData outside an alpha shape
- Assign NoData to the grid outside a polygon
- Use a fault file to define your data limits
- Use a breakline to define a boundary
- Grid the data and specify a reduced search radius
Assign NoData outside the convex hull of data
- Click Home | Grid Data | Grid Data.
- In the Grid Data - Select Data dialog, click Browse in the Dataset 1 field, select the data file and click Open.
- Assign the X, Y, and Z data columns.
- Click Skip to End.
- On the Output page of the Grid Data dialog, check the box Assign NoData outside convex hull of data. This automatically assigns the NoData value to the area outside the convex hull of the data points.
Surfer Grid Data dialog with Assign NoData outside convex hull of data option enabled
If you wish to constrain the gridding inside an even tighter boundary around your data than the convex hull, use one of the following methods.
Assign NoData outside an alpha shape
Assign NoData to grid nodes outside of an alpha shape directly in the Assign NoData, Grid Data, and Grid from Contours dialogs! The Alpha Shape allows you to create a tight polygon boundary around your data points, much like the existing Convex hull option. The Alpha shape can create a concave or convex hull around data points, you control on how tight the polygon clings around the data limits.
Create an alpha shape and use it to assign NoData values when gridding your data.
- Click Home | Grid Data | Grid Data.
- Import the data file and fill out the Grid Data dialog as normal. Learn more in the knowledge base article Gridding Data in Surfer.
- Click Skip to End >> or click Next> until the Grid Data - Output page is showing.
- Change the Assign NoData outside of field to Alpha Shape.
- Change the Alpha value field if desired. The larger the value the more convex the polygon will be, and the smaller the number the move concave the polygon will be.
- Alternatively, if you created an alpha shape in a Base(vector) layer or vector file, import this file into the Assign NoData section.
A Video Tutorial detailing Assigning NoData with an Alpha Shape can be found here.
Assign NoData to the grid outside a polygon
First, create a vector boundary file (BLN, SHP, DXF, etc.) defining the outline of your data points. After the boundary file is created, grid your data as normal by clicking Home | Grid Data | Grid Data, select the data file and specify any gridding parameters you wish. On the Output page, select your polygon boundary, toggle NoData Outside, and click Finish. Create a BLN boundary file or other vector file defining the outline of your data points.
Assign a NoData polygon boundary to your grid file during gridding in Surfer
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 specify any gridding parameters you wish. On the Options page of the Grid Data dialog (Advanced Options in Surfer 16 and earlier versions), expand the Faults section, and specify the BLN as a fault file.
Apply a fault file in Surfer's Grid Data Options to limit interpolation to only the data area.
Only some gridding methods support faults. Kriging does not, but Minimum Curvature which is very similar to Kriging does. See the article Available advanced options for each gridding method in Surfer for additional information.
Use a breakline to define a boundary
This is most useful when trying to create bathymetry contours for a lake or other closed area where the boundary must have a specific Z value.
Create a BLN boundary file defining the outline of your data limits (i.e. the lake edge), including a third column values in the BLN file defining the Z values for the breakline itself (for a lake, this could be an elevation of 0 for the lake edge).
- Click Home | Grid Data | Grid Data.
- In the Grid Data - Select Data dialog,
- Choose your data file from the Dataset 1 list on the right, or click Browse, select the data file, and click Open.
- Choose Kriging from the Gridding Method list on the left.
- Verify your X, Y, and Z columns are set appropriately.
- Click Next.
- In the Grid Data - <Gridding Method> - Options dialog,
- Expand the Breaklines section on the right.
- Click the open file icon in the File containing breaklines field.
- Select the BLN file defining your breakline, and click Open.
- Click Skip to End.
- In the Grid Data - <Gridding Method> - Output dialog,
- Enter a name to save the new grid file as.
- Uncheck Add grid as layer to.
- Click Finish
- Click Grids | Edit | Assign NoData.
- In the Input Grid section, click Browse, select the grid file you just created, and click Open.
- In the NoData Polygon Boundary section, select your base map layer from the list, or click Browse, select the vector file, and click Open.
- Toggle NoData Outside.
- Enter a name to save the new grid file as.
- Choose what type of map layer to create from this grid, and what map to add it to.
- Click OK.
Grid the data and specify a reduced search radius
Click Home | Grid Data | Grid Data, select your data file and specify any gridding parameters you wish. On the Options page of the Grid Data dialog (Advanced Options in Surfer 16 and earlier versions), Expand the Search Neighborhood section. Remove the check mark from the None (use all data) box if necessary, and specify the Radius 1 and Radius 2 values.
Apply a limited search radius to your data interpolation in Surfer's Grid Data dialog
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, and Local Polynomial.
Some gridding methods do not have this option, including Minimum Curvature, Natural Neighbor, Polynomial Regression, and Triangulation with Linear Interpolation. See the article Available advanced options for each gridding method in Surfer for additional information.
Related articles: Create a irregular-shaped map in Surfer
Updated March 2024
Comments
Please sign in to leave a comment.