enviroCar / enviroCar-www

Website of the enviroCar project
http://envirocar.org/
Other
8 stars 10 forks source link

Overall statistics #109

Open nuest opened 11 years ago

nuest commented 11 years ago

Create statstics for complete database ("the current state"):

Think about the temporal resolution of the statistics (archive), potentially cached.

Regarding the website presentation, the page should show the statistics starting with the overall statistics of "just now" and two graphs of three graphs that are interesting to observe over time (no user interaction, just preconfigured graphs)

Other statistics, such as number of cars, users, contributors should be prepared on the server side but not added to the website.

matthesrieke commented 11 years ago

Number of tracks is available through calling https://envirocar.org/api/stable/tracks?limit=1

The HTTP Response Header Link provides links to next and last. The page of the last corresponds to the total number of tracks:

Link: <https://envirocar.org/api/stable/tracks?limit=1&page=384>;rel=last;type=application/json, <https://envirocar.org/api/stable/tracks?limit=1&page=2>;rel=next;type=application/json
nuest commented 11 years ago

Great - I would collect that information in a API though an not use headers. But the code should show how the information can be retrieved server side, which is good.

nuest commented 11 years ago

API sketch (comments welcome @matthesrieke), should probably move this issue to the server.

{
   "source":"www.envirocar.org",
   "statistics":[
      {
         "value":12345.6,
         "id":"tracklength",
         "description":"The accumulated number of the kilometers of all tracks on the enviroCar server.",
         "unit":"km"
      }
   ]
}
matthesrieke commented 11 years ago

I would collect that information in a API though an not use headers

headers can be part of the API. We currently only support HTTP anyhow. But providing nice JSON is also fine with me.

MartinDueren commented 11 years ago

screenshot from 2013-11-15 12 57 16

This is a rough sketch of how we could show some statistics on the landing page. Of course a little fancier ;)

ahitch commented 11 years ago

Am 15.11.2013 12:58, schrieb MartinDueren:

screenshot from 2013-11-15 12 57 16 https://f.cloud.github.com/assets/2618987/1549695/28de7d10-4ded-11e3-9776-8586f05c8561.png

This is a rough sketch of how we could show some statistics on the landing page. Of course a little fancier ;)

— Reply to this email directly or view it on GitHub https://github.com/enviroCar/enviroCar-www/issues/109#issuecomment-28564241.

As long as it is clear what the numbers represent: number of active envirCar participants, number of tracks... What do we want to show?

Ann Hitchcock 52°North Initiative for Geospatial Open Source Software GmbH Martin-Luther-King-Weg 24 48155 Muenster, Germany

tel. +49 (0)251 396371 -21 fax: +49 (0)251 396371 -11

a.hitchcock@52north.org http://52north.org

General Managers: Dr. Albert Remke, Dr. Andreas Wytzisk Local Court Muenster HRB 10849

nuest commented 10 years ago

Discussion of API layout continued in server issue https://github.com/enviroCar/enviroCar-server/issues/170