opendata / Hunting-and-Fishing

Rendering hunting and fishing regulations as open data. [RETIRED]
MIT License
17 stars 3 forks source link

Create records for all species of animals #18

Open waldoj opened 10 years ago

waldoj commented 10 years ago

In no particular order:

waldoj commented 10 years ago

The addition of rabbit is interesting for a couple of reasons.

The first is that it's the initial instance of a species that isn't really a species, but multiple species (eight, in this case). I chose to provide just one name ("Rabbit"), but to provide arrays for taxonomy and bova_id, like such:

"species": {
    "name": "Rabbit",
    "taxonomy": [
        "Lepus americanus",
        "Lepus americanus virginianus",
        "Sylvilagus floridanus mallurus",
        "Sylvilagus floridanus hitchensis",
        "Sylvilagus floridanus mearnsii",
        "Sylvilagus obscurus",
        "Sylvilagus palustris palustris",
        "Lepus californicus"
    ],
    "bova_id": [
        50102,
        50103,
        50104,
        50105,
        50106,
        50107,
        50132,
        50129
    ],
    "url": "http://www.dgif.virginia.gov/wildlife/information/?s=050001"
}

There needs to be a canonical name for each species, and the name field seems like the place to do that. It may be helpful to list of all of the included species in plain English (e.g., "marsh rabbit"), too. Complicating things, DGIF doesn't explicitly list these species, so I just listed every rabbit and hare with a BOVA ID, figuring that those are all of the "rabbits" in Virginia.

The second reason that this is interesting is because it's our first species with a bag limit. I just added bag_limit to the season element, like such:

"season": {
    "method": "firearm",
    "range": {
        "1": {
            "places": {
                "Virginia": {
                    "gnis_id": "TK",
                    "fips_code": 51
                }
            },
            "season": {
                "date": {
                    "starts": "2014-11-01",
                    "ends": "2015-02-28"
                }
            }
        }
    },
    "bag_limit": "Six per day."
}

That seems like a reasonable approach. Taking a cue from the fish data, I'm leaving the bag limit data as English, instead of something like "number": 6, "unit": "days", because there are just going to be too many bag limits that can't be represented with anything other than prose.

waldoj commented 10 years ago

Note that the elk record is really just the deer record, with a few minor tweaks.