# Global Import-Export Market Price Ranking (2017-2023)

For each exporter and HS6 product, compares observed unit values across destination markets, including the highest, lowest, and median prices and traded quantities.

## What one row represents
one exporter and HS6 product

## Included measures and context
- Highest- and lowest-price destination markets
- Median unit value and price spread
- Average quantity and total trade value

## Metric notes
- HS6 codes identify products at the six-digit Harmonized System level.
- Fields marked USD are monetary values denominated in US dollars.
- Values ending in pct are percentages.
- Country fields ending in ISO3 use three-letter ISO 3166-1 country codes.

## Fields
Column names are shown exactly as they appear in the CSV file. The schema lists the same fields, and the sample file shows example values.

- `exporter_iso3` — `fixed_size_binary[3]`
- `hs_code` — `fixed_size_binary[6]`
- `num_markets` — `uint32`
- `highest_price_importer_iso3` — `fixed_size_binary[3]`
- `highest_price_usd_per_ton` — `float64`
- `lowest_price_importer_iso3` — `fixed_size_binary[3]`
- `lowest_price_usd_per_ton` — `float64`
- `median_price_across_markets` — `float64`
- `price_spread_pct` — `float64`
- `avg_quantity_metric_tons` — `float64`
- `total_trade_value_usd` — `float64`

## Coverage and size
- Coverage: 2017-2023 price history summary
- Records: 730,677
- CSV file size: 79.6 MB
- Release: 1.0.0
- SHA-256: `6c93af41165aa7fdcf9b1df56abe80fe47095d15a5a5af997a14e9edaa50d41a`

## Files
- `data.csv` — complete dataset
- `manifest.json` — dataset description, coverage, record count, and download details
- `schema.json` — field names, row definition, included measures, and metric notes
- `sample.json` — example records
- `README.md` — these notes

## Read the CSV file with Python
```python
import pyarrow as pa
import pyarrow.csv as csv

column_types = {
    "exporter_iso3": pa.type_for_alias("string"),
    "hs_code": pa.type_for_alias("string"),
    "num_markets": pa.type_for_alias("uint32"),
    "highest_price_importer_iso3": pa.type_for_alias("string"),
    "highest_price_usd_per_ton": pa.type_for_alias("double"),
    "lowest_price_importer_iso3": pa.type_for_alias("string"),
    "lowest_price_usd_per_ton": pa.type_for_alias("double"),
    "median_price_across_markets": pa.type_for_alias("double"),
    "price_spread_pct": pa.type_for_alias("double"),
    "avg_quantity_metric_tons": pa.type_for_alias("double"),
    "total_trade_value_usd": pa.type_for_alias("double"),
}
reader = csv.open_csv(
    "data.csv",
    read_options=csv.ReadOptions(use_threads=False),
    parse_options=csv.ParseOptions(newlines_in_values=True, ignore_empty_lines=False),
    convert_options=csv.ConvertOptions(
        column_types=column_types, null_values=[""],
        strings_can_be_null=True, quoted_strings_can_be_null=False,
    ),
)
for batch in reader:
    print(batch.num_rows)  # Process one batch at a time.
```

Install `pyarrow` if it is not already available: `python -m pip install pyarrow`.

## Sources and related files
- OECD BIMTS HS2017-6D
- Dataset page: https://www.yugalinks.org/datasets/v1/import-export/import-export-market-price-ranking-v1/
- Original dataset record: https://huggingface.co/datasets/yugalinks/import-export-market-price-ranking-v1

---

Published by Yugalinks: https://www.yugalinks.org/datasets/v1/import-export/import-export-market-price-ranking-v1

Contact: [support@yugalinks.com](mailto:support@yugalinks.com)


## CSV values

The CSV uses UTF-8 and includes the field names in the first row. Country and product codes are text; keep their leading zeros.
An unquoted empty field means unavailable. A quoted empty field is an empty string. Literal text such as NA and null remains text.
Keep the column types shown above when reading numbers, so large counts and decimal values are not rounded.
