NAME:  Surface Tools for Points, Lines and Polygons (v. 1.6) Aka:  surf_tools.avx Last modified:  February 13, 2005 TOPICS:  ArcView 3.x, surface, area, length, slope, aspect, elevation, range, cumulative, ratio, point, line, polygon, GRID, TIN, clip, topography, profile, chart, view, analysis, tools,  3D Analyst, Spatial Analyst AUTHOR: Jeff Jenness Wildlife Biologist, GIS Analyst Jenness Enterprises 3020 N. Schevene Blvd. Flagstaff, AZ 86004 jeffj@jennessent.com DESCRIPTION: This extension allows you to calculate various surface and topographic characteristics for points, lines or polygons in a theme: --> Point Themes: Calculate the X- and Y-Coordinates, the Slope, Aspect and Elevation, and the surface area, flat area and (Surface Area)/(Flat Area) ratios within a circular area surrounding each point. Also calculate the minimum, maximum, mean and standard deviation of elevation values, and identify the high and low points, in that circular area. *** IMPORTANT: REGARDING POINT THEMES: One user has reported errors when points lay exactly on the eastern boundary of the elevation theme, leading to the message “Text cannot be converted to a number: -1.#IND". The author has not been able to pin this problem down yet, but the user has found that shifting the point very slightly to the west solves the problem. --> Line (or Polyline) Themes: Calculate the surface length, the flat length, and the (Surface Length)/(Flat Length) ratio of each line, the minimum slope, maximum slope and average slope of that line, and the start, end, minimum, maximum and average elevation, elevation range and absolute/cumulative elevation change of that line. You can also create a profile chart of the elevation change of the line, and generate a point shapefile of the high and low points on that line. --> Polygon Themes: Calculate the surface area within polygons, the flat area and the (Surface Area)/(Flat Area) ratios within polygons. You can also calculate the surface area and the land volume within each polygon that lies above and below a specified elevation. Finally, you can calculate the highest elevation, the lowest elevation, and the elevation range, mean and standard deviation within each polygon, and you can generate a shapefile of the high and low points within that polygon. GRID or TIN Elevation Theme:  You can use either a GRID or TIN as your elevation theme. If you use a GRID, then this extension will create a TIN of the relevant area and calculate surface and topographic data from the new TIN. Save TINs and Clip TINs: Because this extension uses TINs to calculate most surface and topographic data, it will either use an existing TIN or it will create a new TIN out of an existing elevation GRID. It then clips the TIN to the relevant area and gives you the option to both save these clipped TINs to your hard drive and display them on your screen. Therefore, even if you are not interested in the surface or topographic characteristics of your features, you may still find this extension to be a useful tool for clipping TINs to polygon boundaries. CAUTION: A clipped TIN may not be exactly what you think it is. See the Surface Tools Manual for an explanation of what happens when a TIN is clipped. MULTIPART POLYGONS AND POLYGONS WITH HOLES: This extension works with both multipart polygons (a "single" polygon shape that actually contains multiple polygons), and polygons with holes. Your TINs and your surface/topographic calculations will reflect the correct polygon. ALL OR ONLY SELECTED RECORDS: You can either use all the features (points, lines or polygons) in a theme for the analysis or you can restrict the calculations to a selected subset of features. If any of your features are selected, then only those selected features will be used in the analysis. If no features are selected, then all features in that theme will be used in the analysis. OUTPUT:  Upon completion, you will have a RESULTS table containing any or all of the data mentioned above.  Please see the links below to view explanations of data available for Point, Line or Polygon Input Themes.  You also have the option to create a Point shapefile containing the high and low points near your points, along your lines or within your polygons.  If you are working with a Line (or Polyline) theme, you have the option to create a profile chart of the lines. REQUIRES: This extension requires the Spatial Analyst and 3D Analyst extensions, as well as a feature theme and an elevation theme. The elevation theme can be either a GRID or a TIN, but it must completely encompass the features. This extension also requires that the file "avdlog.dll" be present in the ArcView/BIN32 directory (or $AVBIN/avdlog.dll) and that the Dialog Designer extension be available in the ArcView/ext32 directory, which they almost certainly are if you're running AV3.1 or higher. You don't have to load the Dialog Designer; it just has to be available. ------------------------------------------------------------------------- UPDATES: This extension replaces the extension called "Surface Areas and Ratios." This extension duplicates all functions in "Surface Areas and Ratios" and adds many new functions. - The 1.1 update adds functionality for PointZ, PolylineZ and PolygonZ feature types, and fixes a file-naming error that occurred intermittently when the user chose not to save TINs to the hard drive. - The 1.2 update corrects a logical error made when calculating average slopes, adds the ability to calculate slopes in both "%-Slope" and "Degrees", and adds the ability to save circles around points as a separate polygon shapefile. - The 1.3 update corrects an error with Average Slopes of Lines, in which it wasn't including the first vertex of the line in the Average Slope calculations. - The 1.3a update corrects an error calculating planimetric area when the reference surface dips below 0. - The 1.4 update (December 13, 2003) fixes a bug that occasionally triggered an error with the message "SurfaceTools.SurfaceRatio: Unrecognized object: TIN at 37137”. - The 1.4 revision also adds several tools to the Line Profile window to make it more useful and interesting, allowing the user to customize many aspects of the chart including the vertical exaggeration factor. The revision also adds options to the Polylines window to calculate the beginning and ending elevations of lines, plus whether the line goes predominately up or down. - The 1.4a revision (January 13, 2004) corrects a bug with the “Buffer Factor Help” button, in which it would return the error message “Error in SurfaceTools.BufferHelp2 at 214 -- A(n) Nil object does not recognize request Open” if accessed from the Polyline or Polygon windows. - The 1.5 revision (May 11, 2004) adds the options to calculate the elevation mean and standard deviation within polygons and circular areas around points. Also made some internal changes to speed up the calculation time when identifying high/low points, and to clean up some of the temporary files that previously were left on the hard drive. - The 1.6 revision (February 13, 2005) adds the options to calculate cumulative increases and decreases along polylines, as well as rewrites certain functions to stop it from crashing when using ArcView 3.1. ------------------------------------------------------------------------- GENERAL INSTRUCTIONS: 1) Begin by placing the "surf_tools.avx" file into the ArcView extensions directory (../../Av_gis30/Arcview/ext32/). 2) After starting ArcView, load the extension by clicking on File --> Extensions… , scrolling down through the list of available extensions, and then clicking on the checkbox next to the extension called "Surface Tools for Points, Lines and Polygons" 3)  Decide which feature theme contains the features (points, lines or polygons) you're interested in, and if you want to run this extension on all those features or just a subset of them. If you want to just use a subset of the features, then select those features you're interested in. If any features are selected, then the extension will operate on only those selected features. 4)  For detailed operating instructions, please see the manual "Surface Tools Manual.pdf," (Adobe Acrobat format). For updates to this extension or to view the manual online, go to: Enjoy! If you find bugs or errors, please contact the author at: Jeff Jenness jeffj@jennessent.com 3020 N. Schevene Blvd. Flagstaff, AZ 86004 USA For more ArcView Extensions and other software by the author, please visit the author's software download page at: