Skip to contents

Inspect layer attributes

Usage

layer_attribute_inspect(
  wfs = NULL,
  service = NULL,
  service_version = NULL,
  layer,
  attribute
)

Arguments

wfs

A WFSClient R6 object with methods for interfacing an OGC Web Feature Service.

service

the EMODnet OGC WFS service name. For available services, see emodnet_wfs().

service_version

[Deprecated] the WFS service version. Now always "2.0.0".

layer

character sting of layer name. To get info on layers, including layer_name use emodnet_get_wfs_info().

attribute

character string, name of layer attribute (variable). Use layer_attributes_get_names() to get layer attribute names.

Value

Detailed summary of individual attribute (variable). Particularly useful for inspecting factor or character variable levels or unique values.

Examples

# \dontrun{
wfs <- emodnet_init_wfs_client(service = "biology")
#>  WFS client created successfully
#>  Service: "https://geo.vliz.be/geoserver/Emodnetbio/wfs"
#>  Version: "2.0.0"
layer_attributes_get_names(wfs, layer = "mediseh_zostera_m_pnt")
#> [1] "id"       "country"  "the_geom"
layer_attribute_inspect(
  wfs, layer = "mediseh_zostera_m_pnt",
  attribute = "country"
)
#> # A tibble: 7 × 3
#>   .            n percent
#>   <chr>    <int>   <dbl>
#> 1 Croazia      4  0.0741
#> 2 Francia      1  0.0185
#> 3 Italia      30  0.556 
#> 4 Libia        2  0.0370
#> 5 Slovenia     8  0.148 
#> 6 Spagna       8  0.148 
#> 7 Tunisia      1  0.0185
# }