-
CombiCap: Analytical combination of raster and vector layers
Access this help text as a web page: CombiCap
Presentation
This program analyses and/or effects a spatial combination of two raster layers, a raster layer and a vector layer or two vector layers. For the majority of combinations, the raster layers should be categoric; rasters containing continuous variables are dealt with one of the possibilities in the mixed mode. It is possible to use the raster mode for the combination of layers, allowing the generation of a new raster and/or a report (in TXT and/or CSV [spreadsheet] formats) with statistical tables of the combinations of values of the raster (identified by its categories) or of the attributes of the field in a vector layer (additionally, in the case of a numerical field it is possible to select another alphanumeric field that describes the attributes). A vector mode for the combination of layers is also available. In this case, the database records are combined but no statistics are generated.
Vector mode
A vector mode for the combination of two layers can be
chosen whether the input files are two vector layers, one vector layer and one
raster layer or two categoric raster layers. In this case, the output vector
file, its type and its content will depend on the input file. Thus, a
categoric raster can be considered as a polygon file with a single thematic
raster attribute linked to a thesaurus of categories. More details about
this equivalence relationship can be found in the RasTop application. Exceptions are given by the cases IMG + PNT
= PNT (or IMG + NOD = PNT) and IMG + POL = POL which are commented in the section
mixed mode.
- POL + POL = POL
- IMG + IMG = POL
- The output file is a polygon file that is obtained from the
fragmentation of the space produced by the union of the borders of the
original polygon files. Each fragment inherits all the attributes of both
the original polygons in which is contained.
- POL + ARC = ARC
- IMG + ARC = ARC
- Each arc is divided into fragments based on the borders in the polygon
file derived from the IMG. In addition to its own arc attributes, each
fragment inherits the attributes of the polygon in which is contained.
- POL + ARC = POL
- IMG + ARC = POL
- The geometry of the polygon file remains unaltered but its records
are increased by the attributes of each arc that crosses it or that is
entirely or partially inside.
- POL + PNT = PNT
- The geometry of the point file remains unaltered but each point
acquires the attributes of the polygon it falls within.
- POL + PNT = POL
- IMG + PNT = POL
- The geometry of the polygon file remains unaltered but its records
are increased by the attributes of the points contained in each
polygon.
- POL + NOD = PNT
- The node file is treated as a point file in which each point acquires
the attributes of the polygon it falls within.
- POL + NOD = POL
- IMG + NOD = POL
- The geometry of the polygon file remains unaltered but its records
are increased by the attributes of the nodes falling inside each
polygon.
Note that in the case of vector combinations with a vector as result, all the
attributes of all the principal tables of the two original vectors are taken
into account as well as their relationships with associated tables.
When the analyzed layers have the same field names in the principal table
these are modified by adding _A for the first layer and _B for the second in
order to be able to distinguish them. This is particularly useful for
studying the same parameter at two different times (for example, to compare
two vegetation maps of different dates).
In polygon combinations for which the borders do not originate from the
same source it is possible that small unwanted regions appear that we call
micropolygons (sliver polygons). The program allows these artefacts to be
removed selectively by defining a minimum area and/or a threshold
perimeter/area ratio. For more details see MicroPol.
Mixed mode
IMG + PNT = PNT o IMG + NOD = PNT
A point or node file can be combined with either
categoric rasters or raster files with a continuous variable to create a PNT
file. In this case, the geometry of the point file remains unaltered but each
point acquires the value of the raster cell or cells within one pixel
radius of distance from it. These values are inherited as a new field in the database. When using categoric raster files it is possible to choose between the
nearest cell or the modal value of the cells at less than one pixel radius. For
continuously variable rasters the options are the nearest cell or bilinear
interpolation between the 4 nearest neighbors or bicubic interpolation
between the 16 nearest neighbors.
IMG + POL =POL with statistics
In this case, statistical values of the raster pixels within each polygon are calculated and these statistical values are transferred to the corresponding records of the polygon of the main table (without altering the geometry of the graphic objects). At the edges of the polygon, the raster values will be taken into account according to the combination of the criteria of area and central point. For more information on these criteria consult TiraVec.
The statistics implemented for a continuous quantitative raster are:
Total number of pixels, average, standard deviation, variance, sum, minimum,
maximum and range. The statistics implemented for a categorical raster are: Total number of pixels, modal value, percentage of modal value over the total, index of Shannon, minimum, maximum and range. It should be noted that the NoData values of
raster does not participate in any of the statistical calculations.
Shannon index
Raster mode
To combine two raster files they must cover the same
geographical area, have the same resolution and use the same units referred
to the same reference system. When combining a raster layer and a vector
layer the former defines the area and the resolution of the output. When
combining two vector layers, it is necessary to specify the extent of the
study zone and the resolution of the output raster file. The wCombiCa window
allows a raster file to be used as a template for these parameters. When two
raster images are combined they can be of a different type (real format
images are excluded since these should never be used to represent categories
of data) and the degree of compression does not matter.
As stated previously, the result can be a raster and/or a report. If the
option to generate a raster is selected, this will always be in extra
compressed format and either byte, integer or long format according to the
number of combinations that has resulted from cross correlating the initial
two layers.
The new categories of the resulting raster are given ordered according to
the categories of the first layer, excluding those combinations that,
although theoretically possible, have not been obtained at any geographic
location. The resulting raster will generate a NoData value in those
locations where both layers have a NoData value (either because the input
raster contained such values, or because the input vector file had no
polygons at that point). The value of the NoData will depend on the
automatically selected type of output. The combination of a NoData point
with an allowable value will generate an allowable value and it will be
shown in the legend that this category corresponds to a special combination.
The original categories from which each of the categories originate are
specified in the resulting legend file; if a category in an original file
has no description, the numerical value is specified.
Reports
For raster layers (or layers treated as rasters) the
combination of each value with the values present in the other layer are
analyzed. Given that, the resulting vector layers typically have many fields
and that the statistics of all of them would be confusing, a report can only
be generated if no output layer is chosen (indicating the fields of the
vector layer to combine with the raster) or if the output layer is raster.
If the output layer is vector it is possible to perform attribute queries
with MiraMon to obtain the desired information. Bear in mind that, when an
output layer is not chosen and a report is generated relative to the fields
of the relevant layers, the area calculations for each occurrence of
particular combinations are based on the resolution of the hypothetical
raster output. The first table gives the total number of occurrences of each
pair of values resulting from the combination of the two layers. This is
followed by two tables of percentages. Firstly, the distribution of a
particular value in the first layer amongst the values of the second layer
is shown. The sum of each column will be therefore 100%. The second
percentages table is the same as the first but showing the distribution of
the second layer over the first; in this case the sum of the rows will be
100%.
Finally, two more tables that show the total area of each
combination are generated. The first gives the figures in the specific reference units of the layers used in the analysis (parameter "ResolutionUnits" of raster .REL files) and the second in the area units specified in the
MiraMon parameter file (parameter "UnitArea" of the MiraMon.par file).
The CSV format file details the same information as the text file.
This format has been designed to be read by a spreadsheet such as Microsoft
Excel®. It is a text format in which a particular character acts as a
column break. This character can be specified in the advanced options of the
wCombiCa program. It takes as a default value the character configured as
the list separator in the Windows Control Panel. In the same way as for the
TXT format, it is possible to limit the report width to avoid exceeding the
maximum number of columns supported by the spreadsheet when the number of
categories under consideration is high.
When the text file (format TXT) option is chosen, this is made up
of five tables each with as many columns as there are values in the first
layer and as many rows as there are values in the second layer. The
numerical values of each category are specified in the initial row and
column of each of these tables and the corresponding descriptors are listed
at the end of the first table. The file can be paginated by selecting the
maximum number of columns that fit into the width of the file; by default
this value is 80 columns (categories).
To reduce the volume of information in the reports, some of
the parameters that allow to ignore certain tables can be applied (/NO_FREQ,
/NO_PERCENT, /NO_AREA).
More information can be consulted at the following reference:
Pesquer L, Masó J, Pons X (2000) Herramientas de análisis combinado ráster/vector en un entorno SIG. Aguado I, Gómez M (eds.) Tecnologías Geográficas para el Desarrollo Sostenible. Departamento de Geografía. Universidad de Alcalá, 2000: 53-73. IX congreso del Grupo de Métodos Cuantitativos, Teledetección y SIG de la Asociación de Geógrafos Españoles, Alcalá de Henares.

Dialog box of the application

Graphic examples
 |
Schematic representation of the main possibilities
for the layer analytical combination. |
 |
Example of the use of the mixed mode. |

Syntax
Syntax:
- CombiCap Layer1 Layer2 [/NCOL] [/SEPARA] [/NO_FREQ] [/NO_PERCENT] [/NO_AREA] [/AREA_MIN] [/AREA_PERI_MIN] [/NEXE_CRITERIS] [/FONDRE] [/ATRIB_ELIM] [/INTERPOL] [/OVR_RAS_POL] [/TAULA1] [/CAMP1] [/TAULA_CAT1] [/CAMP_CAT1] [/REPE1] [/TAULA2] [/CAMP2] [/TAULA_CAT2] [/CAMP_CAT2] [/REPE2] [/XMIN] [/XMAX] [/YMIN] [/YMAX] [/COSTAT] [/VORA] [/N_DECIMALS] [/ALGORISME] /FCAPA /FTXT /FCSV
Parameters:
- Layer1
(Layer 1 -
Input parameter): Is the first layer in the combination.
- Layer2
(Layer 2 -
Input parameter): Is the second layer in the combination.
Modifiers:
/NCOL=
(Columns number)
Requests the numerical value for pagination or the maximum report size measured in columns (categories). eg. /NCOL=120. This parameter is only taken into account in the report files (TXT and CSV). Default value is 80. (Input parameter) /SEPARA=
(Separator)
Specifies the list separator needed for the CSV format. Example /SEPARA=; Default value is ';' (Input parameter) /NO_FREQ
(No occurrence)
Avoids the occurrences tables from being written in the report. (Input parameter) /NO_PERCENT
(No percentages)
Avoids the percentages table from being written in the report (Input parameter) /NO_AREA
(No areas)
Avoids the table of areas from being written in the report. (Input parameter) /AREA_MIN=
(Minimum area)
Minimum permitted area for a polygon. (Input parameter) /AREA_PERI_MIN=
(Minimum ratio)
Minimum permitted area/perimeter ratio. (Input parameter) /NEXE_CRITERIS=
(Nex)
If both criteria are specified, eliminates those polygons that satisfy both conditions (AND) or those that satisfy one or other of the conditions (OR). Default value is AND. (Input parameter) /FONDRE=
(Fusion)
Indicates to which polygon should be assigned the space occupied by the deleted micropolygon. Select POL_GRAN to assign the space to the largest adjacent polygon. The default is FRONTERA_MES_LLARGA, which means that the longest arc of the micropolygon is deleted. (Input parameter) /ATRIB_ELIM=
(Absorbs micropolygon)
The polygon that absorbs the micropolygon inherits its attributes if the value is 1. The default is 0, meaning that the micropolygon's attributes are lost. (Input parameter) /INTERPOL=
(Interpolation raster)
The criterion for interpolation of the raster values:- VEI_MES_PROPER: No interpolation; selects nearest value. The default for categoric rasters.
- BILINEAL: Bilinear interpolation (4 neighbors). The default value for continuously variable rasters.
- BICUBICA: Bicubic interpolation (16 neighbors). The second option for continuously variable rasters.
- MODA: Modal value (4 neighbors). Second option for categoric rasters.
(Input parameter) /OVR_RAS_POL=
(Raster and polygon)
Indicates the way of this kin of combination:- VECTOR: Vector view, overlap, fragmentation and attribute transfer. Default option.
- ESTAD: mixt view with statistics fields transfer.
- OCUR: mixt view with histogram transfer by multiple record (under construction).
(Input parameter) /TAULA1=
(Table index of layer 1)
Layer 1 rasterization parameters (only when layer 1 is not a raster): Is the index, numbered from 0, indicating which table in the database contains the relevant attribute field: -1 if it is the principal table or the index of the field of the principal table to which the associated table is linked (normally a thesaurus). (Input parameter) /CAMP1=
(Field index or name of layer 1)
Layer 1 rasterization parameters (only when layer 1 is not a raster): Is the index of the field within the selected table (also numbered from 0) or field name of layer 1 in format string to field BD4 access. These indexing criteria may be found using InfoTop or using the Windows interface of the program (wCombiCa) and pressing the button ">>BAT...". (Input parameter) /TAULA_CAT1=
(Categoric table index of layer 1)
Layer 1 rasterization parameters (only when layer 1 is not a raster): Is the index, numbered from 0, indicating which table in the database contains the relevant attribute field to define raster categories. (Input parameter) /CAMP_CAT1=
(Categoric field index or name of layer 1)
Layer 1 rasterization parameters (only when layer 1 is not a raster): Is the index of the field within the selected table that defines the categories or the field name in format string to field BD4 access. (Input parameter) /REPE1=
(Record of layer 1)
Layer 1 rasterization parameters (only when layer 1 is not a raster): Indicates which record to take in case there are multiple records for the same graphic identifier (1 for the first, 2 for the second, etc.). If shown with a minus sign, the count starts with the last record; if, for example, the second record is chosen but this does NOT exist, then the polygon is not rasterized. Default value is 1. (Input parameter) /TAULA2=
(Table index of layer 2)
Layer 2 rasterization parameters (only when layer 2 is not a raster): Is the index, numbered from 0, indicating which table in the database contains the relevant attribute field: -1 if it is the principal table or the index of the field of the principal table to which the associated table is linked (normally a thesaurus). (Input parameter) /CAMP2=
(Field index or name of layer 2)
Layer 2 rasterization parameters (only when layer 2 is not a raster): Is the index of the field within the selected table (also numbered from 0) or field name of layer 2 in format string to field BD4 access. These indexing criteria may be found using InfoTop or using the Windows interface of the program (wCombiCa) and pressing the button ">>BAT...". (Input parameter) /TAULA_CAT2=
(Categoric table index of layer 2)
Layer 2 rasterization parameters (only when layer 2 is not a raster): Is the index, numbered from 0, indicating which table in the database contains the relevant attribute field to define raster categories. (Input parameter) /CAMP_CAT2=
(Categoric field index or name of layer 2)
Layer 2 rasterization parameters (only when layer 2 is not a raster): Is the index of the field within the selected table that defines the categories or field name in format string to field BD4 access. (Input parameter) /REPE2=
(Record of layer 2)
Layer 2 rasterization parameters (only when layer 2 is not a raster): Indicates which record to take in case there are multiple records for the same graphic identifier (1 for the first, 2 for the second, etc.). If shown with a minus sign, the count starts with the last record; if, for example, the second record is chosen but this does NOT exist, then the polygon is not rasterized. Default value is 1. (Input parameter) /XMIN=
(X minimum)
Defines the minimum X of the extent of the output raster file or the temporal raster that will result in the resulting vector, when TargetEntitiesFile is a vector layer. (Input parameter) /XMAX=
(X maximum)
Defines the maximum X of the extent of the output raster file or the temporal raster that will result in the resulting vector, when TargetEntitiesFile is a vector layer. (Input parameter) /YMIN=
(Y minimum)
Defines the minimum Y of the extent of the output raster file or the temporal raster that will result in the resulting vector, when TargetEntitiesFile is a vector layer. (Input parameter) /YMAX=
(Y maximum)
Defines the maximum Y of the extent of the output raster file or the temporal raster that will result in the resulting vector, when TargetEntitiesFile is a vector layer. (Input parameter) /COSTAT=
(Pixel side)
Determines the side of the pixel in the output raster image or the temporal raster that will result in the resulting vector, when TargetEntitiesFile is a vector layer. (Input parameter) /VORA
(Border)
When combining polygons with arcs, or polygons with points, (with vectorial output) a point or a piece of arc that exactly coincides with a polygon border it is considered to apply to both polygons. If it is not indicated it is considered that the arc or point do not apply to any of the polygons. (Input parameter) /N_DECIMALS=
(Decimals figures)
Decimal figures of the output file. (Input parameter) /ALGORISME=
(Algorithm)
This parameter is used to determine the type of algorithm that the application will use to cut the vectors in the topological structuring.- ESCOMBRATGE: Based on the intersection of segments Bentley-Ottmann.
- DIRECTE: Based on the exploration of all segments against all segments to determine the intersections between vectors in the topological structuring.
- AUTOMATIC: MiraMon automatically decides which of the two algorithms used.
(Input parameter) /FCAPA=
(Name of the layer file)
Is the name of the output layer that will be generated by the program. One of the following permitted file types must be chosen: .IMG .POL .ARC .PNT (see table of possible results). Example /FCAPA=C:\RESULT.IMG (Output parameter) /FTXT=
(Statistics table)
Is the name of the text file where the program will write the statistics table. It may have any extension. (Output parameter) /FCSV=
(Statistics file)
Is the name of the file where the statistics will be written in CSV format (spreadsheet import format). (Output parameter)
