meikpiep / gauguin

Gauguin is a Sudoku-like game for Android where you solve grids via calculation and logic.
GNU General Public License v3.0
110 stars 6 forks source link

Fix calculation of average value in statistics #87

Closed mccartney closed 5 months ago

mccartney commented 9 months ago

I fail to understand what does phi (Φ) is supposed to mean in the Statistics page. Screenshot_20240218-222431.jpg

meikpiep commented 9 months ago

It means 'average value'. In German, this is a usual sign for this. Is it unsuitable in English?

mccartney commented 9 months ago

Well, this was my first thought. But how come average is 4 if min is 24?

mccartney commented 9 months ago

Also re English - I don't think the symbol is used that widely for average, at least in non technical contexts. But I am not a native speaker.

In such contexts I saw three letters "avg" being used.

meikpiep commented 9 months ago

"avg" should be fine.

Nevertheless, I didn't even read the values of the screenshot, sorry for that. Will investigate the numbers.

mccartney commented 8 months ago

Will investigate the numbers

Could it be that the actual logic of calculations is fine on paper, but it's based on incomplete data?

A random thought looking at: https://github.com/meikpiep/gauguin/blob/02245da9dc05b715a7ff8d5ab4a7a9faca1cb57c/gauguin-app/src/main/kotlin/org/piepmeyer/gauguin/ui/statistics/StatisticsActivity.kt#L146

mccartney commented 8 months ago

Maybe use solvedDuration.size() instead of overall.gamesSolved as the denominator?

meikpiep commented 8 months ago

Sorry for the delay, I'm kind of busy to calculate game difficulties on Azure, using a limited offer from Microsoft.

solvedDuration and other lists get cut to have a maximum of 50 values, so we can't use them as a source for all games played. Maybe, the data have to be restructured to enable proper calculations like this. That would lead to every installation being forced to reset their statistics...

meikpiep commented 8 months ago

Feel free to add your ideas!

meikpiep commented 8 months ago

FYI: The label got corrected.

meikpiep commented 5 months ago

@mccartney I had a look at the code mentioned by you - you are right that the statistics of your installation are not consistent, but I think that is caused by the migration of the statistics values some months ago. This should not occur in new installations which d not hold migrated statistics data.

Sadly, you'd have to reset your statistics to fix this in your installation, as I do not find any stable fix regarding the old migrated data.