Skip to contents

Read the metadata of a BPS dataset.

Usage

bps_metadata(data)

Arguments

data

A tibble with the bpsr_tbl subclass.

Value

A list with the bpsr_metadata class.

See also

Examples

# Read the metadata of personal care and other services inflation dataset
inflation <- bps_get_dataset("1927", lang = "eng")
bps_metadata(inflation)
#> <bpsr_metadata>
#> List of 10
#>  $ dataset_id  : chr "1927"
#>  $ dataset     : chr "Calender Year Inflation of Personal Care and Other Services Group and Sub (2018=100)"
#>  $ vertical_var: chr "90 Inflation City (2018=100)"
#>  $ subject     : chr "Consumer Prices Indices"
#>  $ methodology : NULL
#>  $ activity    : NULL
#>  $ note        : chr "&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Since 2020, CPI has been based on a consumption pattern obta"| __truncated__
#>  $ def         : chr ""
#>  $ decimal     : chr "2"
#>  $ var         : chr ""

# Read the metadata of a trade dataset
trade <- bps_get_trade_hs_chapter("01", "export")
bps_metadata(trade)
#> <bpsr_metadata>
#> List of 7
#>  $ note      : chr "Sumber : https://www.bps.go.id diakses pada 10-09-2023 22:47:34 WIB"
#>  $ hs_chapter: chr "Kode dan Deskripsi dari HS"
#>  $ port      : chr "Pelabuhan Masuk/Keluar di Indonesia"
#>  $ country   : chr "Negara Asal/Tujuan"
#>  $ year      : chr "Tahun Data"
#>  $ net_weight: chr "Berat Ekspor/Impor dalam Kilogram (KG)"
#>  $ export    : chr "Nilai Ekspor/Impor dalam US Dollar ($)"