Weight-class: Weight class (Internally Used)

Description Fields Methods

Description

A wrapper class for GeoDaWeight class

Fields

gda_w

An object of GeoDaWeight

is_symmetric

If weights matrix is symmetric

sparsity

Sparsity of weights matrix

density

Density of weights matrix

min_neighbors

Minimum number of neighbors

max_neighbors

Maximum number of neighbors

num_obs

Number of observations

mean_neighbors

Mean number of neighbors

median_neighbors

Median number of neighbors

has_isolations

If the weights matrix has any isolations

Methods

GetDensity()

Get density computed from weights matrix

GetNeighborWeights(idx)

Get weights values of neighbors for idx-th observation, idx starts from 0

GetNeighbors(idx)

Get neighbors for idx-th observation, idx starts from 0

GetPointer()

Get the C++ object pointer (internally used)

GetSparsity()

Get sparsity computed from weights matrix

HasIsolations()

Check if weights matrix has isolates, or if any observation has no neighbors

IsSymmetric()

Check if weights matrix is symmetric

SaveToFile(out_path, layer_name, id_name, id_values)

Save current spatial weights to a file.

out_path: The path of an output weights file
layer_name : The name of the layer of input dataset
id_name : The id name (or field name), which is an associated column contains unique values, that makes sure that the weights are connected to the correct observations in the data table.
id_values : The tuple of values of selected id_name (column/field)

SpatialLag(idx, values)

Compute spatial lag values of idx-th observation, idx starts from 0

initialize(o_gda_w)

Constructor with a GeoDaWeight object (internally used)


lixun910/rgeoda documentation built on March 19, 2021, 3:49 p.m.