For Python learners & researchers

A real question.
A small script.

How many Nobel chemistry recipient records are listed for each year? Start with a CSV, write a short analysis, and learn why counting rows is only part of the answer.

Python 3 · Standard library only · No API key for the sample

Expected sample output10 input rows

Count records.
Then question the count.

Counts from the current ten-row sample used in this example
YearRecipient records
20131
20143
20153
20163

The 2013 count reflects a partial year in this sample. These are sample-row counts, not a claim about all laureates or prizes in those years.

Run it against a local file

CSV in.
A first result out.

Save the download as nobelwinnerschemistry.csv beside your script. The Nobel Prize Winners in Chemistry dataset includes Year, FullName, and Country.

The script validates that Year is numeric and stops if it finds duplicate year/name pairs, so you can investigate before counting.

Python 3 / Local CSV
import csv
from collections import Counter

with open("nobelwinnerschemistry.csv", newline="",
          encoding="utf-8-sig") as source:
    rows = list(csv.DictReader(source))

seen = set()
counts = Counter()
for row in rows:
    year = int(row["Year"])
    identity = (year, row["FullName"].strip())
    if identity in seen:
        raise ValueError(f"Check duplicate: {identity}")
    seen.add(identity)
    counts[year] += 1

for year, count in sorted(counts.items()):
    print(year, count)

Decide what the result means before charting it.

Once the sample run makes sense, download the complete file, rerun the same script, and check its coverage and sources. Your output should change with the input; sample counts are not an answer about the whole dataset.

When you need the whole list

Take your project
past the sample.

The sample is enough to check your script. A pass lets you run it over every available chemistry record and explore other Nobel category lists.

A Data Pass includes complete files in CSV, JSON, and XML, API access, and category ZIPs across the available catalog.

Data Pass

$39one payment / 365 days

Choose your pass

Your key arrives by email. No account to create and no automatic renewal.

For your own projects, coursework, teaching, research, and internal work. If you incorporate data into a product or service you provide to others, choose a Commercial Pass. Check the dataset’s scope and sources before buying; passes are non-refundable under our terms.