Learn R Programming

geozoning (version 1.0.0)

findN: findN

Description

findN

Usage

findN(K, listN, iZ, minSize = 0.012)

Arguments

K

zoning object, as returned by the calNei function

listN

list of neighbor zones

iZ

index of current zone in zoning

minSize

minimum admissible zone size

Value

the index of the zone into which to merge the current zone

Details

Find the neighbor zone into which to merge the current zone. It must be a neighbor in the sense of Voronoi polygons. In case of ties, choose the smallest zone for merging into

Examples

Run this code
# NOT RUN {
data(mapTest)
data(resZTest)
K=resZTest
Ns=geozoning:::getNs(K$zoneNModif,4) # neighbors of zone 4
listN =  grep( TRUE , Ns) # zones 2 and 5
findN(K,listN,4) # zone 4 will be merged into zone 5
# not run
# }

Run the code above in your browser using DataLab