Stats for Opencaching sites

Du suchst die richtigen GPS-Geräte, Geocaching-Software oder sonstiges Geocaching-Zubehör? Tausche Dich hier mit anderen Usern aus.

Moderator: mic@

Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

Hi,

I'm developing a tool to compute various statistics related to Opencaching activity and a cache map. It supports all OC sites which use OKAPI. The tool itself is accompanied by a simple webpage to visualize the results and you can check it out here: http://tomaszg.pl/geo/.

It is still work in progress and especially all international features were not extensively tested. Myself, I use only OC.pl so many things may break. Also I still intend to add new features, so all ideas are welcome.

If anyone is interested to contribute, the source code is hosted at https://gitlab.com/tomaszg/geostat.
Bild Bild
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

Hi Tomasz, it seems that this year 2020 ist the year of statictics.
We have already two statictics for oc.de available ;)

Regarding Your website: My nick (mic@) is not accepted:
==> Incorrect characters in nick d.
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

[quote="mic@"]
Regarding Your website: My nick (mic@) is not accepted:
==> Incorrect characters in nick d.
[/quote]

Ah, didn't expect a "@". Should work now.

BTW. Your German language question captcha is a bit annoying ;)
Bild Bild
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

[quote="tomaszg"]Ah, didn't expect a "@". Should work now.[/quote]

Wow, thx for the fast reaction.
The statistic is very beautiful !!!

Is there a chance to get an overall statistic, for example a heatmap of ALL oc.de users?
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

[quote="mic@"]
Is there a chance to get an overall statistic, for example a heatmap of ALL oc.de users?
[/quote]
Do you mean just a heatmap of cache locations or heatmap of finds? In any case OKAPI doesn't allow it easily. It limits the amount of data user can pull. I would have to clone the database on my end and work with it. I'm doing that for OC.pl to plot caches not found but it is slow and requires storing the data locally on my server. I could try to do it. For OC.pl it is easy to get the cache heatmap by checking "not found" toggle and specifying a user without any finds (or with minimal one).

BTW. I just realized that OC.de hosts a lot of "Safari" reverse caches. I should probably try to exclude them from geographic part of stats. Too bad they don't have a separate cache type... I explicitly excluded "own" and "mobile" type of caches already.
Bild Bild
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

I downloaded the data dump and rendered a cache density heat map:

Bild

Bild
Bild Bild
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

[quote="tomaszg"]Do you mean just a heatmap of cache locations or heatmap of finds?[/quote]

Correct.
So the result would be something like this here:
http://www.flopp.net/heatmap
Unfortunately this heatmap is only for caches, not for finds.


[quote="tomaszg"]BTW. I just realized that OC.de hosts a lot of "Safari" reverse caches. I should probably try to exclude them from geographic part of stats. Too bad they don't have a separate cache type... I explicitly excluded "own" and "mobile" type of caches already.[/quote]

All safari caches have a specific attribute.
Maybe this could help for building the right filter.
And "maybe" we will fix this problem soon, because there is the idea of
simplifying the cache types (e.g. remove math caches and introduce safari cache).

Your maps look great - thank You very much!
Zuletzt geändert von mic@ am 28.01.2020, 21:43, insgesamt 1-mal geändert.
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

[quote="mic@"]
Correct.
So the result would be something like this here:
http://www.flopp.net/heatmap
Unfortunately this heatmap is only for caches, not for finds.
[/quote]
If I find the time, I'll try to prepare something for finds. I'll probably only upload a generated image, but it might be fun to create a web interface to be able to trace geocaching activity in a given time period.

[quote="mic@"]
All safari caches have a specific attribute.
Maybe this could help for building the right filter.
And "maybe" we will fix this problem soon, because there is the idea of
simplifying the cache types (e.g. remove math caches and introduce safari cache).
[/quote]
I noticed that. My code is not yet ready to handle attributes but when it does I'll try to filter them out.
Bild Bild
Benutzeravatar
FriedrichFröbel
Vereinsmitglied
Vereinsmitglied
Beiträge: 568
Registriert: 04.09.2012, 18:21

By the way: It seems like umlauts are not allowed inside the user name as well at the moment.
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

Now it should work. I managed to get better unicode support in my web script and I hope I didn't break anything else by doing that.
Bild Bild
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

Added a bit of stuff last month: display of "trail" instead of heatmap (works so-so), time range (i.e. limiting stats to caches found in a certain period), added stars next to names of recommended caches, and a few minor polishing things.
Bild Bild
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

Thank You for your great wirk.

I just trid to view my statictics again, but it failed:
OKAPI error: "Parameter 'cache_codes' has invalid value: Duplicate codes detected (make sure each cache is referenced only once)."

I tried it with "mic@" and german map
Benutzeravatar
tomaszg
Nano
Nano
Beiträge: 22
Registriert: 28.01.2020, 03:18

It seems I reintroduced an old bug with these changes. Should be fixed now.
Bild Bild
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

[quote="tomaszg"]Should be fixed now.[/quote]

Yes, it works smoothly again. Thank You for Your work!
Normally I am not a big statistic fan, but it makes fun to watch my caching behaviour in numbers and caches.
Very cool!
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6513
Registriert: 04.12.2009, 00:31

Is it possible to allow statistics only for the owner himself/herself?

Actual I am possible to view any oc-user just by replacing USERNAME with the correct user (e.g.: zelda):
http://tomaszg.pl/cgi-bin/geo-form.pl?n ... ap=Germany
turns to
http://tomaszg.pl/cgi-bin/geo-form.pl?n ... ap=Germany

So it´s a bit like "big brother is watching you"...
Antworten