Area(面积(Area))¶
Supported in: Batch, Streaming
Calculates area of a geometry in meters squared using a spherical approximation of the globe. For a line string or a point, this equals 0.
Expression categories: Geospatial
Declared arguments¶
- Expression: GeoJSON string.
Expression\
Output type: Double
Examples¶
Example 1: Base case¶
Argument values:
- Expression:
geometry
| geometry | Output |
|---|---|
| {"type":"Polygon","coordinates":[[[-1.0,-1.0],[1.0,-1.0],[1.0,1.0],[-1.0,1.0],[-1.0,-1.0]]]} | 4.945989326791108E10 |
| {"type":"Polygon","coordinates":[[[-179.0,-1.0],[179.0,-1.0],[179.0,1.0],[-179.0,1.0],[-179.0,-1.0]]]} | 4.945989326791108E10 |
| {"type":"Polygon","coordinates":[[[-102.05,41.0],[-109.05,41.0],[-109.05,37.0],[-102.05,37.0],[-102.05,41.0]]]} | 2.6893150148718735E11 |
| {"type":"MultiPolygon","coordinates":[[[[-102.05,41.0],[-109.05,41.0],[-109.05,37.0],[-102.05,37.0],[-102.05,41.0]]],[[[-1.0,-1.0],[1.0,-1.0],[1.0,1.0],[-1.0,1.0],[-1.0,-1.0]]]]} | 3.1839139475509845E11 |
| {"type":"LineString","coordinates":[[0.0,0.0],[1.0,0.0]]} | 0.0 |
| {"type":"Point","coordinates":[0.0,0.0]} | 0.0 |
| {"type":"Polygon","coordinates":[[[10.201057,-45.051191],[10.201081,-45.051243],[10.201088,-45.05125... | 410.5095025699564 |
| null | null |
| not geoJson | null |
中文翻译¶
面积(Area)¶
支持:批处理(Batch)、流处理(Streaming)
使用地球球面近似法计算几何图形以平方米为单位的面积。对于线串(LineString)或点(Point),计算结果为 0。
表达式类别: 地理空间(Geospatial)
声明的参数¶
- 表达式(Expression): GeoJSON 字符串。
表达式\
输出类型: Double
示例¶
示例 1:基础案例¶
参数值:
- 表达式:
geometry
| geometry | 输出 |
|---|---|
| {"type":"Polygon","coordinates":[[[-1.0,-1.0],[1.0,-1.0],[1.0,1.0],[-1.0,1.0],[-1.0,-1.0]]]} | 4.945989326791108E10 |
| {"type":"Polygon","coordinates":[[[-179.0,-1.0],[179.0,-1.0],[179.0,1.0],[-179.0,1.0],[-179.0,-1.0]]]} | 4.945989326791108E10 |
| {"type":"Polygon","coordinates":[[[-102.05,41.0],[-109.05,41.0],[-109.05,37.0],[-102.05,37.0],[-102.05,41.0]]]} | 2.6893150148718735E11 |
| {"type":"MultiPolygon","coordinates":[[[[-102.05,41.0],[-109.05,41.0],[-109.05,37.0],[-102.05,37.0],[-102.05,41.0]]],[[[-1.0,-1.0],[1.0,-1.0],[1.0,1.0],[-1.0,1.0],[-1.0,-1.0]]]]} | 3.1839139475509845E11 |
| {"type":"LineString","coordinates":[[0.0,0.0],[1.0,0.0]]} | 0.0 |
| {"type":"Point","coordinates":[0.0,0.0]} | 0.0 |
| {"type":"Polygon","coordinates":[[[10.201057,-45.051191],[10.201081,-45.051243],[10.201088,-45.05125... | 410.5095025699564 |
| null | null |
| not geoJson | null |