Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new column average_rating to game_stats #282

Open
Crotalus opened this issue Aug 7, 2021 · 6 comments
Open

Add new column average_rating to game_stats #282

Crotalus opened this issue Aug 7, 2021 · 6 comments

Comments

@Crotalus
Copy link
Member

Crotalus commented Aug 7, 2021

I'm working on a bot command to show top rating replays for a specific period, i.e. list replays max 1 week old with high rated players.

The current poor man version is something like this:
https://api.faforever.com/data/game?include=playerStats.player&sort=startTime&page[limit]=1&filter=startTime=gt=2021-08-01T11:58:02Z;playerStats.player.globalRating.rating=gt=2000
Then I at least get a game with at least one player having globalRating.Rating > 2000 but that could be a high rated player bashing noobs. Another problem is that it is the current rating, not the rating when the game was played.

What I really want is to be able to query and sort on the players average_rating of a game, I guess this would require a new column to game_stats which is then populated by the python server at start?

@Crotalus
Copy link
Member Author

Crotalus commented Aug 7, 2021

Moved the issue to the API repo

@Crotalus Crotalus closed this as completed Aug 7, 2021
@Brutus5000 Brutus5000 reopened this Aug 7, 2021
@Brutus5000
Copy link
Member

Brutus5000 commented Aug 7, 2021

It's fine to have the issue in all related repos as they need dedicated Pull Requests.
This feature was also requested for better replay search.

@Sheikah45
Copy link
Member

Sheikah45 commented Aug 7, 2021

Ah that feature is not exactly the same. That feature is just to have the shown rating so mean-3*dev as a column in the leaderboardRatingJournal this is the aggregation of those ratings on a per gamebasis. Dependent but not quite the same.

@Brutus5000
Copy link
Member

No, you could just query the games instead of the players then. Would be a cheaper search.

@Sheikah45
Copy link
Member

Ah you are right I missed that ability. Although still complicated with the multiple ratings per game

@Brutus5000
Copy link
Member

Damn I didn't think about that. Needs additional thoughts 😞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants