Skip to content

topojson.core.join

Join

Bases: Extract

This class targets the following objectives: 1. Quantization of input linestrings if necessary 2. Identifies junctions of shared paths

The join function is the second step in the topology computation. The following sequence is adopted: 1. extract 2. join 3. cut 4. dedup 5. hashmap

Parameters:

Name Type Description Default
data _any_ geometric type

Geometric data, as for Extract

required
options dict or TopoOptions

Options of the topology, see Topology

None

Returns:

Type Description
dict

Output of Extract with the key junctions, and transform if quantized

to_dict

to_dict()

Convert the Join object to a dictionary.

to_svg

to_svg(separate=False, include_junctions=False)

Display the linestrings and junctions as SVG.

Parameters:

Name Type Description Default
separate boolean

If True, each of the linestrings will be displayed separately. Default is False

False
include_junctions boolean

If True, the detected junctions will be displayed as well. Default is False

False