Ask any Filipino where it's coldest in the country and they'll say Baguio without hesitating. Ask them how much cooler it actually is, and you'll get vague answers. "Jacket weather." "Sweater cold." I wanted numbers instead of vibes, so I turned to the OpenWeatherMap API and started collecting.
Over several weeks of batch requests, I gathered 447,000 weather records across 138 Philippine cities, covering 2023 and into 2024. Temperature, humidity, wind speed, weather descriptions — all of it timestamped and city-tagged.
What I Built
A city-level weather comparison dashboard built from API data. The project includes temperature rankings, seasonal breakdowns, humidity analysis, and heat index calculations for every city in the dataset. I also built wet-versus-dry season comparisons and identified which cities experience the most extreme conditions.
How I Put It Together
The biggest challenge wasn't the analysis — it was the data collection. OpenWeatherMap's free tier has strict rate limits, so I couldn't just fire off 138 requests at once and call it a day. I wrote a Python script that batched requests with time.sleep() delays between calls, stored results in a local SQLite database, and picked up where it left off if anything crashed.
Each API call returned current weather for one city. To build a meaningful dataset, I ran the script multiple times a day over weeks, accumulating observations at different hours. This gave me time-of-day variation, which turned out to be really valuable for the heat index analysis.
Cleaning was straightforward compared to other projects. API data is structured by design. The main issue was handling cities where the API returned coordinates slightly off from the actual city center — I cross-checked a sample against known locations to make sure I wasn't accidentally pulling weather for the wrong spot.
What the Data Showed
Baguio really is the outlier. Its average temperature sat around 6 to 8 degrees Celsius below cities at sea level. That gap held consistent across months, not just during the amihan (cool dry) season. The elevation effect is real and measurable.
The wet season versus dry season split was dramatic for some cities and barely noticeable for others. Cities on the eastern seaboard — facing the Pacific — saw more evenly distributed rainfall throughout the year. Western cities had a much sharper dry-wet divide, with months of barely any rain followed by monsoon dumps.
Heat index was the most sobering part. Several cities regularly hit "danger" levels during afternoon hours in April and May, where the combination of temperature and humidity creates conditions that are genuinely risky for outdoor workers. These aren't rare events. They're daily patterns for weeks at a time.
- Baguio averaged 6-8°C cooler than lowland cities year-round
- Eastern seaboard cities had more evenly spread rainfall
- April-May heat index reached danger thresholds in multiple cities daily
- Humidity varied more by time of day than by city in most lowland areas
Looking Back
This was my first big API-driven data collection project, and the rate limiting problem taught me more about engineering patience than any textbook could. The analysis itself was relatively simple once I had the data. The hard part was getting the data in the first place without getting my API key throttled.
With a longer collection window — say, 5 or 10 years — this dataset could support real climate trend analysis. Even just one year showed clear patterns, but a single year can't tell you whether those patterns are shifting.
Want to see all the charts and data tables?
View the Full Analysis →