In Surfer, you can assign a null or NoData value to grid nodes outside multiple polygons. You can do so either using the files directly (without first creating a map) or by creating a map first to view the data and then assigning NoData.
How to assign NoData outside multiple polygons
- Click Home | New Map | Contour, select your grid file and click Open.
- Select the map and click Home | Add to Map | Layer | Base.
- Select the file containing the polygons you want to use for assigning NoData and click Open. This enables you to verify that the polygons are in the correct location on the map.
- Click Grids | Edit | Assign NoData.
- In the Assign NoData to Grid dialog:
- Select the grid file used to create the contour map from the Input Grid drop down.
- Select the base layer from the NoData 2D Polygon Boundary drop down.
- Choose NoData Outside for the NoData direction
- Set the Output Grid name and format.
- Check Add grid as layer to: to add the grid as a layer to the Map, if desired.
- Click OK. The layer is added. You can turn off the original layer (or delete it) in the Contents window.
How to assign NoData outside multiple polygons in Surfer 13 or older
In Surfer v13 and previous versions, you could not blank grid nodes outside multiple polygons without combining the polygons first into a single complex polygon. 'Blanking' was the term used in Surfer 13 and previous versions instead of 'Assign NoData', but it means the same thing. If the polygons were not combined, then the entire grid would be blanked (have NoData for all nodes) since the area outside one polygon includes the other polygon, and vice versa.
The area outside Polygon A includes Polygon B, and vice versa, which causes the entire grid to be assigned NoData when using multiple, separate polygons.
You can use the Geoprocessing | Edit Boundaries | Combine Islands/Lakes command to combine multiple polygons into a single complex polygon, and then use the polygon when blanking the grid. The exact steps are as follows:
- Click Home | New Map | Base | Base, select the original BLN file and click Open. A base map is created showing the existing polygons.
- In the Object Manager window, click the button to expand the Base layer.
- Right click over the Base layer and click Edit Group.
- Press CTRL+A to select all the polygons in the group.
- Click Geoprocessing | Edit Boundaries | Combine Islands/Lakes. Now the multiple polygons are combined into a single complex one. Even though they don't look any different on the screen, you can see the Object Manager that there is just one polygon now.
- Right click over the Base layer and click Stop Editing Group.
- With the Base layer selected in the Object Manager, on the General page in the Property Manager, click the Save As button.
- In the Export dialog, give the file a name, choose a location to save the new file, and choose to save it as a BLN. Click Save.
- In the Export dialog, enter a File name, change the Save as type to BLN Golden Software Blanking (*.bln), and click Save.
- In the Export Options, click the BLN Options tab and choose an option for Blank areas. Click OK.
The BLN file that is created will contain one complex polygon and can be used to blank the grid file outside that polygon, using the Grid | Blank command.
In Surfer versions prior to v11, you would need to open the BLN file in the worksheet and manually edit it to combine all the polygons into one complex polygon, and resave the BLN file.
Updated March 2024
Comments
Please sign in to leave a comment.