playground explore freely · no grades
SQL Playground
Explore any Runtime dataset with SQL. Nothing here affects course progress.
Three years (2022–2024) of daily observations from 100 NOAA weather stations serving 96 U.S. cities: temperatures, rain, snow and wind.
110,557 rows5 tables2022-01 – 2024-12
tables
Open a table to see what one row means, its columns and keys, and a preview. Start from daily_weather: it is the dataset's central table.
states51 rows · 4 columns
One U.S. state or the District of Columbia.
- state_code
USPS state code
- state_name
State name
- census_region
Northeast, Midwest, South or West
- census_division
U.S. region division
cities96 rows · 6 columns
One city with weather coverage, including its map location.
- city_id
City key
- city_name
City name
- state_code
State
- latitude
City latitude
- longitude
City longitude
- land_area_sq_mi
Land area of the incorporated place, square miles
stations100 rows · 10 columns
One weather station (usually at an airport). A city can have more than one station.
- station_id
Weather station ID
- station_name
Station name
- city_id
City the station represents
- is_primary
1 for the station nearest the city’s internal point
- latitude
Latitude
- longitude
Longitude
- elevation_m
Elevation in metres
- first_observation
Earliest observation date in this dataset
- last_observation
Latest observation date in this dataset
- reported_days
Days with at least one reported measurement
calendar1,096 rows · 10 columns
One calendar date, 2022–2024.
- date
Calendar date (YYYY-MM-DD)
- year
Year
- month
Month number
- day_of_year
Day of the year, 1–366
- day_of_week
0 = Sunday … 6 = Saturday
- meteorological_season
winter (Dec–Feb), spring, summer or autumn
- day_of_month
Day of the month, 1–31
- day_name
Sunday … Saturday
- is_weekend
1 for Saturday or Sunday
- quarter
Calendar quarter, 1–4
daily_weather109,214 rows · 10 columns
One day of weather for one station. If a station did not report that day, there is no row.
- station_id
Station
- observation_date
Local observation date
- tmax_c
Maximum temperature, °C
- tmin_c
Minimum temperature, °C
- precipitation_mm
Precipitation, mm; 0 with precip_trace = 1 means a trace
- precip_trace
1 when precipitation was a trace (too small to measure)
- snowfall_mm
Snowfall, mm
- snow_depth_mm
Snow depth on the ground, mm
- avg_wind_speed_ms
Average wind speed, m/s
- peak_gust_ms
Fastest 2-minute wind speed, m/s
relationships
How to join these tables. Left column matches the right column.
- cities.state_code joins to states.state_code
- stations.city_id joins to cities.city_id
- daily_weather.station_id joins to stations.station_id
- daily_weather.observation_date joins to calendar.date