title: ChartJS changing displayed data based on dropdown selection
body: <p>I'm working on a project that uses ChartJS to display line graphs to show comparison data based on the team or person selected.</p>
  
  <p>Here is the HTML:</p>
  
  <pre><code>&lt;script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.1.4/Chart.min.js"&gt;&lt;/script&gt;
  
  &lt;div class="compare-team-summary-container"&gt;
  
    &lt;div id="compare-team-sales"&gt;
  
      &lt;div class="title-selection-container"&gt;
        &lt;div class="compare-main-title"&gt;
          COMPARE TEAM SALES
          &lt;br&gt;
          &lt;span&gt;1/1 - 1/7&lt;/span&gt;
        &lt;/div&gt;
        &lt;div class="team-selection-container"&gt;
          &lt;select class="team-one"&gt;
            &lt;option value="Sample One"&gt;Sample One&lt;/option&gt;
            &lt;option value="Person Two"&gt;Person Two&lt;/option&gt;
            &lt;option value="Individual Three"&gt;Individual Three&lt;/option&gt;
            &lt;option value="Option Four"&gt;Option Four&lt;/option&gt;
          &lt;/select&gt;
          &lt;select class="team-two"&gt;
            &lt;option value="Sample 1A"&gt;Sample 1A&lt;/option&gt;
            &lt;option value="Option Two"&gt;Option Two&lt;/option&gt;
            &lt;option value="Person Three"&gt;Person Three&lt;/option&gt;
            &lt;option value="Individual Four"&gt;Individual Four&lt;/option&gt;
          &lt;/select&gt;
        &lt;/div&gt;
        &lt;div class="clear"&gt;&lt;/div&gt;
      &lt;/div&gt;
  
      &lt;div class="sales-team-graphs"&gt;
        &lt;canvas id="myChart"&gt;&lt;/canvas&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  
  &lt;/div&gt;
  </code></pre>
  
  <p>The CSS..</p>
  
  <pre><code>html,
  body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background: #f2f2f2;
    color: #ffffff;
    font-size: 16px;
    line-height: 28px;
    font-family: 'Lato', 'Oswald', 'Open Sans', sans-serif;
  }
  
  .clear {
    clear: both;
  }
  
  .compare-team-summary-container {
    color: #797979;
    text-align: center;
    margin: 10px 20px 50px 20px;
  }
  
  .compare-team-summary-container #compare-team-sales {
    background: #ffffff;
    padding: 15px 20px;
    border-radius: 4px;
    margin: 5px 10px 10px;
    text-align: left;
    width: 700px;
    height: 400px;
    display: inline-block;
    vertical-align: top;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container {
    margin-bottom: 30px;
    padding-bottom: 16px;
    border-bottom: 1px #dedede solid;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .compare-main-title {
    font-weight: bold;
    line-height: 24px;
    float: left;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .compare-main-title span {
    font-size: 14px;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .team-selection-container {
    float: right;
    margin-top: 10px;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .team-selection-container .team-one {
    background: transparent;
    border: 0;
    border-radius: 3px;
    width: 220px;
    height: 36px;
    padding: 0 10px;
    margin-top: -3px;
    font-size: 13px;
    color: #ffffff;
    margin-right: 14px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: url(../images/icons/down-chevron-white.png) 96% / 6% no-repeat #5da7e4;
    cursor: pointer;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .team-selection-container .team-one option {
    background: transparent;
    border: 0;
    border-radius: 3px;
    width: 220px;
    height: 36px;
    padding: 0 10px;
    margin-top: -3px;
    font-size: 13px;
    color: #ffffff;
    margin-right: 14px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: #5da7e4;
    cursor: pointer;
  }
  
  .compare-team-summary-container #compare-team-sales .title-selection-container .team-selection-container .team-two {
    background: transparent;
    border: 0;
    border-radius: 3px;
    width: 220px;
    height: 36px;
    padding: 0 10px;
    margin-top: -3px;
    font-size: 13px;
    color: #ffffff;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: url(../images/icons/down-chevron-white.png) 96% / 6% no-repeat #303e7b;
    cursor: pointer;
  }
  
  .compare-team-summary-container #compare-team-sales .sales-team-graphs {
    height: 350px;
    margin-top: -99px;
  }
  </code></pre>
  
  <p>and JavaScript...</p>
  
  <pre><code>Chart.defaults.global.legend.display = false;
  Chart.defaults.global.tooltips.enabled = false;
  
  var ctx = document.getElementById('myChart').getContext('2d');
  
  Chart.defaults.global.responsive = true;
  
  var myChart = new Chart(ctx, {
    type: 'line',
    data: {
      labels: ['M', 'T', 'W', 'T', 'F', 'S', 'S', 'M'],
      datasets: [{
        lineTension: 0,
        label: 'sample one',
        data: [50403, 28403, 30309, 60987, 34876, 22987, 10890, 46734],
        backgroundColor: "rgba(125, 209, 255, 0.77)"
  
      }, {
        lineTension: 0,
        label: 'sample 1a',
        data: [32403, 42403, 66403, 28906, 44878, 37890, 12978, 39865],
        backgroundColor: "rgba(48, 62, 123, 1)"
      }]
    },
    options: {
      responsive: true,
      maintainAspectRatio: false,
      scales: {
        yAxes: [{
          gridLines: {
            display: false
          },
          ticks: {
            display: false,
            min: 0,
            max: 110000,
            fixedStepSize: 10000
          }
        }],
        xAxes: [{
          ticks: {
            display: false
          }
        }],
      },
      elements: {
        point: {
          radius: 0
        }
      },
      scaleShowLabels: false,
    }
  });
  </code></pre>
  
  <p>Here is the fiddle:
  <a href="https://jsfiddle.net/antondaniels/c34uo667/3/" rel="nofollow noreferrer">https://jsfiddle.net/antondaniels/c34uo667/3/</a></p>
  
  <p>I can't figure out how to only display 2 graphs for comparison in the same color, and tie in the dropdown selector to toggle that information.</p>
  
  <p>Any help would be greatly appreciated!</p>