12

What's the difference between LineString and MultiPoint in GeoJSON?

To me the examples given are identical. http://geojson.org/geojson-spec.html#id3.

I'm planning some things in GeoJSON and if something as basic as this is confusing I'm in trouble.

danuker
  • 861
  • 10
  • 26
Greg
  • 2,359
  • 5
  • 22
  • 35

2 Answers2

21

A LineString is a Polyline or from Wikipedia "a curve specified by the sequence of points". So if you like to do a track or route based on latitude and longitude for a map application - use LineString.

MultiPoint is simply a collection of points without lines between them. Say a group of people. So the use cases are very different.

TomSjogren
  • 769
  • 10
  • 20
5

Specification of LineString requires at least two positions.

Other than that there is only a difference in intent. LineString defines a line through the points in given order. MultiPoint defines a finite collection of points.

zch
  • 14,931
  • 2
  • 41
  • 49