GithubHelp home page GithubHelp logo

pay-to-play's Introduction

screen shot 2017-10-06 at 9 48 13 am

Pay to Play

Pay to Play is a data visualization analyzing a subset of the most highly compensated athletes in 2017, according to a Forbes Article. It allows users to see see statistics like number of major championships won, years competing as a professional, total compensation, and additional info when hovering over the athlete's bubble. It also allows for filtering by sport and compensation bracket.

Check it out here: http://paytoplay.tech

Technology

Pay to Play is a frontend application built on JavaScript, HTML, and CSS. The D3.js library (v4) was used to attach data to HTML elements, which enables the user to smoothly and quickly access information about the athletes:

var svg = d3.select("body").append("svg")
    .attr('class', 'grid')
    .attr("width", width + margin.left + margin.right)
    .attr("height", height + margin.top + margin.bottom)
var athletes = svg.append('g')
  .attr('class', 'athletes')

Features

Athlete Tooltip

In order to create an tooltip with data, D3.js was used to assign JSON data to the athlete HTML elements. With this data stored, I used D3 to create a mouseover tooltip effect which shows specific athlete information related to their compensation and professional career.

screen shot 2017-10-06 at 11 00 53 am

Combination Filtering

The user has the option to filter the view both by sport and by total compensation. Using a combination of D3, HTML, and CSS, I used class addition and removal to create filters that adjust the visibility of groups of elements. By styling visibility based on the presence of multiple classes rather than a single class, the athletes shown is derived from multiple filters as opposed to just one.

screen shot 2017-10-06 at 11 02 19 am

Future Considerations

  • If additional reliable data is obtained, it would be interesting to see what these athletes make in salary relative to their team's salary cap
  • Adding country data for the athletes

pay-to-play's People

Contributors

dtluther avatar

Watchers

James Cloos avatar  avatar

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.