Name

Majority Vector —

Synopsis

Synopsis

ca.spatial.gis.vector.Majority {blockShapeFile} {blockLabel} {millShapeFile} {costColumn} {roadLabel} {roadShapeFile1} {roadShapeFile2}
      

Arguments

NameTypeDefault
blockShapeFile None
blockLabel None
millShapeFile None
costColumn None
roadLabel None
roadShapeFile1 None

Description

The Majority tool will help summarize the composition of a polygon coverage. This tool assumes that you have two polygon coverages (a set of base polygons and a set of zone polygons) that have been unioned together. The input coverage is the result of the union operation. The 'zone' parameter identifies the column name that contains zone information, and the 'column' parameter identifies a unique column label from the base polygon layer.

The program will scan through all of the attribute records in the unioned coverage. It will compute the polygon area, and keep a tally of each 'zone' that is present in each base polygon. When complete, the program will write out a file containing one record for each base polygon. The record will contain the base polygon label, and the label of the zone that covered the majority of area of the base polygon.

Processing Notes

Although this program executes very quickly, the preparation steps involved in unioning the coverages may be time consuming. Another alternative to this program is the raster version Majority tool.

See Also

Compute Zone Majority (raster)

Examples

      java -jar patchworks.jar ca.spatial.gis.vector.Majority
           unioned.shp MARTEN BLOCK lookup.csv
    

In this example, the file 'unioned.shp' contains the union of two input coverages. The column 'MARTEN' contains the identifier for the zone polygons. The BLOCK label contains the identifier for each base polygon. The output will be written to a file named 'lookup.csv'