Hello everybody!

I want to check Google Charts to rebuild a column chart similar to this one:

[image: snippet_iw_columns.jpg]

Now my question: is it possible to adjust the data or the options to show 
*small 
image icons on the hAxis *instead of just the text "Player 1-10"?

My code:

<html>
  <head>
    <script type="text/javascript" 
src="https://www.gstatic.com/charts/loader.js";></script>
    <script type="text/javascript">
      var data;
      var chart;

      google.charts.load('current', {'packages':['corechart', 'bar', 
'table']});

      google.charts.setOnLoadCallback(drawScorer);


      function drawScorer() {
        // set data
        var topAssistColor = 'color:#b3bdc7;';
        var topGoalerColor = 'color:#cd3223;';
        
        data = new google.visualization.arrayToDataTable(
        [
          ['Kategorie', 'Vorlagen', {role: 'style'}, 'Tore', {role: 
'style'}, { role: 'annotation' }],
          ['Player 1', 6, topAssistColor, 8, , '14'],
          ['Player 2', 6, topAssistColor, 8, , '14'],
          ['Player 3', 4, , 9, topGoalerColor, '13'],
          ['Player 4', 4, , 7, , '11'],
          ['Player 5', 4, , 7, , '11'],
          ['Player 6', 3, , 8, , '15'],
          ['Player 7', 6, topAssistColor, 4, , '10'],
          ['Player 8', 5, , 4, , '9'],
          ['Player 9', 1, , 7, , '8'],
          ['Player 10', 0, , 8, , '8']
        ]
        );
        
        // set options
        var options = {      
          annotations: {
            alwaysOutside: true,
            textStyle: {
            bold: true,
            color: '#08111f'
            }
          },
          title:'Spieler-Rangliste Scorer',
          titleTextStyle:{
            color: '#6b7d8b',
            bold: true
          },
          tooltip: {
              textStyle: {
              color: '#08111f',
              bold: true
            },
            showColorCode: true
          },
          width: 600,
          height: 450,
          legend: { position: 'right' },
          isStacked:true,
          colors:['#e4e4e4','#e69078'],
          hAxis: { 
            baselineColor: '#d7d7d7',
            gridlines: {color: '#333', count: 1}
          },
          vAxis: {
            ticks: [5,10,15],
            baselineColor: '#d7d7d7'
          }          
        };
        
        chart = new 
google.visualization.ColumnChart(document.getElementById('drawArea'));
        chart.draw(data, options);
      }
    </script>
  </head>
  <body>
  <div id="drawArea"></div>
  </body>
</html>

Thanks & greetz
Thommy

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-visualization-api/4a1072c6-79eb-449a-8689-29566ec0f61f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to