ct_services: Get Services Trade Data

View source: R/trade.R

ct_servicesR Documentation

Get Services Trade Data

Description

Download international services trade data from the UN Comtrade database using the EBOPS (Extended Balance of Payments Services) classification.

Usage

ct_services(
  reporter,
  partner = "0",
  service = "TOTAL",
  flow = c("X", "M"),
  year = NULL,
  cache = TRUE
)

Arguments

reporter

Character. Reporter country ISO3 code.

partner

Character. Partner country code. Default "0" (World).

service

Character. EBOPS service code. Default "TOTAL".

flow

Character. Trade flow: "X" (exports), "M" (imports). Can be a vector. Default c("X", "M").

year

Integer. Year(s) to query (2000-present). Default: most recent available year.

cache

Logical. Cache results locally. Default TRUE.

Value

A data.frame with columns: reporter, reporter_desc, partner, partner_desc, flow, flow_desc, service_code, service_desc, year, trade_value_usd.

Examples


op <- options(comtrade.cache_dir = tempdir())

# UK services exports to the world
ct_services("GBR", year = 2022, flow = "X")

options(op)


comtrade documentation built on April 13, 2026, 5:07 p.m.