Read a Feather file. Uses standard metadata information to identify geometry columns and coordinate reference system information.

st_read_feather(dsn, col_select = NULL, ...)

Arguments

dsn

character file path to a data source

col_select

A character vector of column names to keep. Default is NULL which returns all columns

...

additional parameters to pass to FeatherReader

Value

object of class sf

Details

Reference for the metadata used: https://github.com/geopandas/geo-arrow-spec. These are standard with the Python GeoPandas library.

See also

Examples

# load Natural Earth low-res dataset. # Created in Python with GeoPandas.to_feather() path <- system.file("extdata", package = "sfarrow") world <- st_read_feather(file.path(path, "world.feather")) world
#> Simple feature collection with 177 features and 5 fields #> Geometry type: GEOMETRY #> Dimension: XY #> Bounding box: xmin: -180 ymin: -90 xmax: 180 ymax: 83.64513 #> Geodetic CRS: WGS 84 #> First 10 features: #> pop_est continent name iso_a3 gdp_md_est #> 1 920938 Oceania Fiji FJI 8.374e+03 #> 2 53950935 Africa Tanzania TZA 1.506e+05 #> 3 603253 Africa W. Sahara ESH 9.065e+02 #> 4 35623680 North America Canada CAN 1.674e+06 #> 5 326625791 North America United States of America USA 1.856e+07 #> 6 18556698 Asia Kazakhstan KAZ 4.607e+05 #> 7 29748859 Asia Uzbekistan UZB 2.023e+05 #> 8 6909701 Oceania Papua New Guinea PNG 2.802e+04 #> 9 260580739 Asia Indonesia IDN 3.028e+06 #> 10 44293293 South America Argentina ARG 8.794e+05 #> geometry #> 1 MULTIPOLYGON (((180 -16.067... #> 2 POLYGON ((33.90371 -0.95, 3... #> 3 POLYGON ((-8.66559 27.65643... #> 4 MULTIPOLYGON (((-122.84 49,... #> 5 MULTIPOLYGON (((-122.84 49,... #> 6 POLYGON ((87.35997 49.21498... #> 7 POLYGON ((55.96819 41.30864... #> 8 MULTIPOLYGON (((141.0002 -2... #> 9 MULTIPOLYGON (((141.0002 -2... #> 10 MULTIPOLYGON (((-68.63401 -...
plot(sf::st_geometry(world))