zlacker

[parent] [thread] 2 comments
1. ajfrie+(OP)[view] [source] 2025-02-07 17:40:57
It depends on if you want to model a point or an area. lat/lng gives you a point, but you often want an area to, for example, count how many people are in that area. A spatial index like H3 provides a grid of area units.
replies(1): >>HappMa+ca
2. HappMa+ca[view] [source] 2025-02-07 18:37:13
>>ajfrie+(OP)
But so do lat long ranges.
replies(1): >>ajfrie+gz
◧◩
3. ajfrie+gz[view] [source] [discussion] 2025-02-07 21:08:33
>>HappMa+ca
You can use those if they work for your application. One downside would be that you're storing 4 numbers compared to a single `int64` index with H3.

You also have to decide how you'll do that binning. Can bins overlap? What do you do at the poles? H3 provides some reasonable default choices for you so don't have to worry about that part of your solution design.

[go to top]