<https://lh3.googleusercontent.com/-_ugW3D4yOMY/WeDJJPxODHI/AAAAAAAAAQg/LKfk0YbsQGgj6UVbp90ZOnbEHBQ1cU5jQCLcBGAs/s1600/areachart.PNG>

How to add a point inside the Google Charts Visualization: Area chart like 
the red point in the picture shown above and can i put some label above or 
beside the point?

Here is the code that outputs the chart above

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

  function drawChart() {
    var data = new google.visualization.DataTable();
    data.addColumn('string', 'Output1');
    data.addColumn('number', 'Height');
    data.addColumn({type:'string', role:'annotation'});
    data.addRows([
      <?php echo"['',  2, null],"; ?>
      <?php echo"['',  2, '1 Kpa ---------->'],"; ?>
      <?php echo"['2',   1, '<---------- 2'],"; ?>
      <?php echo"['3 σ',   0, '<---------- 3 σ']"; ?>
    ]);

    var options = {
      title: 'Total Stress',
      hAxis: {title: '<-------- Direction',  titleTextStyle: {color: '#333'}},
      vAxis: { ticks: [{v:2, f:'1 Kpa ->'}, {v:1, f:'1 m'},{v:0, f:'length ^ 1 
m'},{v:0, f:'1 m'}] }
    };

    var chart = new 
google.visualization.AreaChart(document.getElementById('total_stress'));
    chart.draw(data, options);
  }

-- 
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 google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
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/baef83bc-6287-43f1-a893-55ec91e1f272%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to