Calculating Feature Attributes
Global Mapper can perform a number of operations that calculate attributes based on other loaded data, selected styling or geometry properties of the features such as measurements and coordinates.
These tools are generally grouped in the Digitizer Menu under Attribute/ Style Functions, with some additional related tools under Analysis/ Measurement.
For information on manually editing attributes see Modify Feature Info. To calculate attribute values based on other attributes see Attribute Calculator.
Existing attributes can be visualized using the Attribute Editor or Feature Info Tool.
Add Attributes with Count of Points and Lines in Selected Area(s)…
Select area feature to add a count of point and line features in the selected area feature as an Attribute to the selected Area Feature.
The new Attributes will appear as POINT_COUNT for contained points and LINE_COUNT for contained lines.
This tool cam be combined with drawing style
for the areas based on the new POINT_COUNT or LINE_COUNT attribute on the Area Styles
tab of the Options dialog for the layer that the areas are in, to color based on how many points or lines were in each area. This is one method for creating a thematic map that bins dense point or line features into a visualization that is easier to understand.
Add Pixel Coordinates to Selected Points
This tool is available when points are selected and a raster layer, including imagery or terrain is loaded. Raster layers within a Map Catalog will also be considered. This operation will add new attributes to the selected point features LAYER_PIX, LAYER_PIXX, and LAYER_PIXY. The values indicate the layer description of the raster layer used to add the value, and the pixel row and pixel column coordinates from the raster layer where the point appears. If multiple raster layers are loaded, the pixel coordinates from the first found raster layer at the point location will be used.
Add Coordinate Attributes to Selected Features
This tool will add a coordinate attribute to selected feature.
If one or more point features are selected, the Add Coordinate Attributes to Selected Point(s) option will appear when right-clicking. Selecting this option will cause X and Y attributes to be added (or updated if they already exist) to the selected points with the value being the coordinates of the points in the current projection system.
To add Latitude and Longitude coordinates, first change the display projection to Geographic, then perform this operation. The projection can be changed back once the attributes are calculated.
Add Style Attributes to Selected Feature(s)
This tool adds attribute that represent the Point, Line or Area Style that has been set for each feature. When attributes of this type are found in vector features loaded into Global Mapper, the defined style is automatically applied and recognized. This style definition is unique to Global Mapper, but does produce attributes that would be displayed in other GIS applications.
For more information on the attributes that are added, see Style Attributes.
Calculate/ Copy Attributes for Feature Selection
This allows you to create a new attribute value (or update an existing one) by copying the value of some attribute, performing a mathematical operation either between two attributes or an attribute and some number, or to append some text string to a value when Simple Calculation is selected.
The dialog below is displayed when you select this option to allow you
to set it up:
Selecting Use Formula Calculation
option enables the use of additional formulas.
Available Attributes: User may
select an attribute to insert into the current formula (use the Insert
button to the right)
Available Functions: User may select
a function template to insert into the current formula, which includes
the function name and dummy parameters where they're expected. Insert
the function using the button immediately to the right. Changing the current
function in the list displays a function description in the read-only
control directly below the function selector.
Enter Formula to Use: An edit control
where the user types in the formula that they require.
Insertions from the Available Attributes and Available Functions drop downs
determine the current insertion point in this control, and replace any
current selection. As changes are made to the formula, a status is updated
in the Status control immediately below.
Status: Indicates the status of the current formula. If the formula is non-empty, it is evaluated for correctness. If there is no error, then the status will be 'OK'. Otherwise, if there is an error an indication of what the error is displayed. In addition, if there is no error, then the dialog used the current feature in whatever feature collection is being considered to evaluate the value that the formula would compute, as a sample. This is shown below the status.
Use the 'Insert' button to the right of the selected Function to insert a function to use and the 'Insert' button to the right of Available Attributes to add the Attribute name to the string. If the formula is invalid or empty, the 'Calculate' button is disabled. Clicking 'Calculate' will apply the formula to the feature collection.
For more information see Attribute Calculator.
Load Local/ Web Files from an Attribute of Selected Features
This operation will load local files or a URL
referenced in an attribute of the selected feature.
Set Text Color
When a point, line or area feature with a label is selected, tho option may be used to quickly change the color of the label's text. Selecting this option will display a color picker dialog.