mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-02-06 14:10:02 +00:00
19 lines
660 B
Plaintext
19 lines
660 B
Plaintext
|
title: $:/plugins/tiddlywiki/geospatial/docs/geodistance
|
||
|
caption: geodistance operator
|
||
|
tags: $:/tags/GeospatialDocs
|
||
|
|
||
|
!! `geodistance` operator
|
||
|
|
||
|
The `geodistance` operator calculates the distance between two points in [[GeoJSON Point Feature]] format. The points are specified as two operands. An optional third operand specifies the units as `miles`, `kilometers`, `degrees` or `radians` (defaults to `miles`).
|
||
|
|
||
|
```
|
||
|
<$let
|
||
|
oxford={{{ [geopoint[51.751944],[-1.257778]] }}}
|
||
|
new-york={{{ [geopoint[40.730610],[-73.935242]] }}}
|
||
|
>
|
||
|
<$text text={{{ [geodistance<oxford>,<new-york>] }}}/>,
|
||
|
<$text text={{{ [geodistance<oxford>,<new-york>,[miles]] }}}/>,
|
||
|
</$let>
|
||
|
```
|
||
|
|