Git Product home page Git Product logo

5aside's People

Contributors

dependabot[bot] avatar samdking avatar

Watchers

 avatar  avatar  avatar

Forkers

davshoward

5aside's Issues

Incorporate void games

Todo:

  • Add "void" flag to matches
  • Allow games to be marked as void when added
  • Output "void" attribute on matches in JSON API responses
  • Disregard void matches from points, wins, draws, losses, handicap, etc. metrics

Add single player endpoint

New endpoint to target a player based on their ID:

/api/player/

/api/player/1 = returns object for Sam King.

Include all matches that player participated in as well.

Single endpoint for all seasons

/api/seasons currently returns the all-time leaderboard, and /api/seasons/{year} returns the leaderboard for that year. There's no end point currently which returns all the leaderboards for the years (maybe including all time as well).

This would be a useful endpoint for the Yearly pages on mnf.davshoward.com, which currently has to dissect manually each match, which leads to slight inaccuracies (e.g. https://github.com/davshoward/mnf/issues/6) and worse performance over time as data increases.

Should there be a breaking change, so that /api/seasons returns an object containing all the seasons, or should I add a non-RESTful URL like /api/seasons/all which returns them all.

Combinations Spec

Combinations Spec

/api/combinations
/api/combinations?from=2018-01-01
/api/combinations?any=5,4,3,56,23
/api/combinations?all=1,4,8
/api/combinations?minSize=4&maxSize=5
/api/combinations?minMatches=5
/api/combinations?minMatches=5&order=[wins|games|losses]

Originally posted by @samdking in #5 (comment)

Additional data on season end-point

Given that the season endpoint now is the primary connection, it's important to get the additional data added in order to reduce the client-side computation of static data.

  • Add advantaged and disadvantaged object with played, wins, losses, draws
  • Add form array e.g. ["Win", "Win", "", "Win", "Loss", "Draw"] (gaps are for no appearance)

Add end point for highest win percentages leaderboard

For this data:

Best win percentages

  1. Dan, 2015: 61.9% (56% match attendance) - 13 wins
  2. Sam, 2016: 61.1% (84%) - 22 wins
  3. Aaron, 2018: 58.3% (71%) - 21 wins
  4. Dan, 2018: 55% (78%) - 22 wins
  5. Mike, 2018: 54.8% (61%) - 17 wins
  6. Davs, 2019 54.2% (91%) - 26 wins
  7. Sam, 2017: 54.1% (86%) - 20 wins
  8. Rob, 2016: 53.8% (91%) - 21 wins
  9. Davs, 2016: 53.7% (95%) - 22 wins
  10. Dan, 2016: 51.3% (91%) - 20 wins

Proposal: Remove Short Matches

The concept of short matches was added to accommodate for mid-match changes to teams. Be it through injury or 1 team massively beating another. There were 3 instances where this occurred (twice in 2015 and once in 2017). A similar event occurred recently, in 2020, and it was decided a new match type ("void") should be created to represent this match.

Void matches count towards attendance and partnerships but nothing else. Scores nor results are recorded.

The problem with short matches

  • Attendance counts as double (provided you didn't drop out through injury)
  • Results in a short match carry the same weight as results in a full match
  • They're untidy and largely obsolete now due to void matches

Proposal

  • Remove the 2nd of each pair of short matches
  • Change the 1st of each pair to be void (and scrub the result)
  • Add injury flags for the 2 occurrences were injury changed the teams

Affected matches

  • 22nd June 2015: 10 - 1
  • 22nd June 2015: 4 - 6
  • 20th July 2015: 11 - 4
  • 20th July 2015: 6 - 4
  • 3rd April 2017: 3 - 3
  • 3rd April 2017: 16 - 7

Knock-on effects

This will mean:

  • A reduction in Pld, W, D, L, F, A, Pts totals for those involved in any of the short matches
  • A change in GD and Win % (for some positively, for others negatively)

However, if it is done before the next match (provisionally 7th December 2020):

  • No attendance milestones (100, 200) will be affected
  • No win milestones (50, 100) will be affected
  • In the all time rankings, only 1 meaningful change of position will occur (Alex will drop from 13th to 15th)
  • No change to the top 4 of the 2015 leaderboard
  • No change to the top 4 of the 2017 leaderboard

Current top 20 all-time leaderboard

Screen Shot 2020-11-19 at 19 50 25

New top 20 all-time leaderboard

Screen Shot 2020-11-19 at 19 49 43

V2: API

The current site (V1) is going to be replaced via a Javascript frontend, designed and built by @davshoward (with help from me where necessary). The backend is going to replaced with an API with at least the functionality which the current site offers. Namely:

  • Leaderboards (by year and all time)
  • Matches
  • Player overall stats
  • Player teammate stats
  • Player opponent stats
  • Player with/against ratios

The API will be developed to offer the following data, as a starting point:

  • More sophisticated leaderboards
  • Streaks/records
  • Combinations
  • Configurable teammate/opponent stats
  • Attendance stats

The frontend could offer the following enhancements:

  • Visual graphs
  • Dynamic sorting/filtering of tables
  • Subtle animations

The aim of this change is to gift the site a facelift, make it more easily editable (by more people), and add a more dynamic interface; in addition to offering more information.

Please respond with additional suggestions for enhancements to the new front end or API.

Add "all" seasons to player endpoint

Is it possible to add an aggregated "all" seasons object in the player endpoint?

Either just add it under "seasons" named "all" or a new object titled something like "all_seasons".

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.