waldoj / frostline

A dataset, API, and parser for USDA plant hardiness zones.
https://phzmapi.org/
MIT License
149 stars 25 forks source link

Handle missing ZIPs #14

Open waldoj opened 7 years ago

waldoj commented 7 years ago

e.g., 55555 (Young America, MN). This is because there is no PHZ data for this ZIP. But don't just 404—provide something useful. (Or maybe 404 is better?)

webmaven commented 7 years ago

Is the reason there is no PHZ data for this zipcode (and other zipcodes) known?

Hypothesis: Any zipcodes that have more than one Zone within them are missing, because a more precise geolocation query would be needed to get an unambiguous result.

Corollary: Zipcodes that fall along the PHZ boundaries are the ones that are missing.

waldoj commented 7 years ago

No, I'd never found out why some ZIPs are just missing data, but my guess was the same as yours. I never could find a decent polygon of 55555, to figure out if it's just really big because Minnesota.

webmaven commented 6 years ago

After doing some digging, I think 55555 doesn't actually have a polygon (or perhaps it is the same polygon as 55397, depending on your mental model). The code (along with the entire range from 55550 to 555560 inclusive, and any other zip starting with 555) is a sort of virtual zip used for some arcane mail routing purpose, related to the fact that Young America is where a huge volume of mail-in submissions for public contests and rebate claims (handled by Young America Corporation) are sent.