Coordinate reference system is always WGS84 in accordance with GeoJSON RFC.
Arguments
- str
Single string containing GeoJSON.
- opts
Named list of GeoJSON-specific options. Usually created with
opts_read_geojson(). Default: emptylist()to use the default options.- ...
Any extra named options override those in GeoJSON-specific options -
opts- json_opts
Named list of vanilla JSON options as used by
read_json_str(). This is usually created withopts_read_json(). Default value is an emptylist()which means to use all the default JSON parsing options which is usually the correct thing to do when reading GeoJSON.- filename
Filename
Examples
geojson_file <- system.file("geojson-example.json", package = 'yyjsonr')
read_geojson_file(geojson_file)
#> prop0 prop1 geometry
#> 1 value0 <NA> 102.0, 0.5
#> 2 value0 0.000000 102, 103, 104, 105, 0, 1, 0, 1
#> 3 value0 {"this":"that"} 100, 101, 101, 100, 100, 0, 0, 1, 1, 0
