AI-generated Key Takeaways
- 
          The Google Bubble Chart is an SVG or VML visualization that represents data with up to four dimensions using bubble position (X and Y), color, and size. 
- 
          Basic usage involves loading the corechartpackage from the Google Charts library and providing data in a specific format with columns for ID, X, Y, color/series, and size.
- 
          Bubbles can be colored based on numerical values using the colorAxisoption.
- 
          The appearance of bubble labels can be customized using the bubble.textStyleoption.
- 
          The chart offers numerous configuration options for axes, titles, interactivity, and more, and provides methods for drawing, getting information about elements, and handling events. 
Overview
A bubble chart that is rendered within the browser using SVG or VML. Displays tips when hovering over bubbles.
A bubble chart is used to visualize a data set with two to four dimensions. The first two dimensions are visualized as coordinates, the third as color and the fourth as size.
Example
<html>
  <head>
    <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
    <script type="text/javascript">
      google.charts.load('current', {'packages':['corechart']});
      google.charts.setOnLoadCallback(drawSeriesChart);
    function drawSeriesChart() {
      var data = google.visualization.arrayToDataTable([
        ['ID', 'Life Expectancy', 'Fertility Rate', 'Region',     'Population'],
        ['CAN',    80.66,              1.67,      'North America',  33739900],
        ['DEU',    79.84,              1.36,      'Europe',         81902307],
        ['DNK',    78.6,               1.84,      'Europe',         5523095],
        ['EGY',    72.73,              2.78,      'Middle East',    79716203],
        ['GBR',    80.05,              2,         'Europe',         61801570],
        ['IRN',    72.49,              1.7,       'Middle East',    73137148],
        ['IRQ',    68.09,              4.77,      'Middle East',    31090763],
        ['ISR',    81.55,              2.96,      'Middle East',    7485600],
        ['RUS',    68.6,               1.54,      'Europe',         141850000],
        ['USA',    78.09,              2.05,      'North America',  307007000]
      ]);
      var options = {
        title: 'Fertility rate vs life expectancy in selected countries (2010).' +
          ' X=Life Expectancy, Y=Fertility, Bubble size=Population, Bubble color=Region',
        hAxis: {title: 'Life Expectancy'},
        vAxis: {title: 'Fertility Rate'},
        bubble: {textStyle: {fontSize: 11}}
      };
      var chart = new google.visualization.BubbleChart(document.getElementById('series_chart_div'));
      chart.draw(data, options);
    }
    </script>
  </head>
  <body>
    <div id="series_chart_div" style="width: 900px; height: 500px;"></div>
  </body>
</html>Color By Numbers
You can use the colorAxis option to color the bubbles
in proportion to a value, as shown in the example below.
<html> <head> <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script> <script type="text/javascript"> google.charts.load("current", {packages:["corechart"]}); google.charts.setOnLoadCallback(drawChart); function drawChart() { var data = google.visualization.arrayToDataTable([ ['ID', 'X', 'Y', 'Temperature'], ['', 80, 167, 120], ['', 79, 136, 130], ['', 78, 184, 50], ['', 72, 278, 230], ['', 81, 200, 210], ['', 72, 170, 100], ['', 68, 477, 80] ]); var options = { colorAxis: {colors: ['yellow', 'red']} }; var chart = new google.visualization.BubbleChart(document.getElementById('chart_div')); chart.draw(data, options); } </script> </head> <body> <div id="chart_div" style="width: 900px; height: 500px;"></div> </body> </html>
Customizing Labels
You can control the bubble typeface, font, and color with
the bubble.textStyle option:
var options = { title: 'Fertility rate vs life expectancy in selected countries (2010).' + ' X=Life Expectancy, Y=Fertility, Bubble size=Population, Bubble color=Region', hAxis: {title: 'Life Expectancy'}, vAxis: {title: 'Fertility Rate'}, bubble: { textStyle: { fontSize: 12, fontName: 'Times-Roman', color: 'green', bold: true, italic: true } } };
<head> <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script> <script type="text/javascript"> google.charts.load("current", {packages:["corechart"]}); google.charts.setOnLoadCallback(drawChart); function drawChart() { var data = google.visualization.arrayToDataTable([ ['ID', 'Life Expectancy', 'Fertility Rate', 'Region', 'Population'], ['CAN', 80.66, 1.67, 'North America', 33739900], ['DEU', 79.84, 1.36, 'Europe', 81902307], ['DNK', 78.6, 1.84, 'Europe', 5523095], ['EGY', 72.73, 2.78, 'Middle East', 79716203], ['GBR', 80.05, 2, 'Europe', 61801570], ['IRN', 72.49, 1.7, 'Middle East', 73137148], ['IRQ', 68.09, 4.77, 'Middle East', 31090763], ['ISR', 81.55, 2.96, 'Middle East', 7485600], ['RUS', 68.6, 1.54, 'Europe', 141850000], ['USA', 78.09, 2.05, 'North America', 307007000] ]); var options = { title: 'Fertility rate vs life expectancy in selected countries (2010).' + ' X=Life Expectancy, Y=Fertility, Bubble size=Population, Bubble color=Region', hAxis: {title: 'Life Expectancy'}, vAxis: {title: 'Fertility Rate'}, bubble: { textStyle: { fontSize: 12, fontName: 'Times-Roman', color: 'green', bold: true, italic: true } } }; var chart = new google.visualization.BubbleChart(document.getElementById('textstyle')); chart.draw(data, options); } </script> </head> <body> <div id="textstyle" style="width: 900px; height: 500px;"></div> </body> </html>
Labels on the above chart are hard to read, and one of the reasons
is the white space around them. That's called an aura, and if
you'd prefer your charts without them, you can set
bubble.textStyle.auraColor to 'none'.
var options = { title: 'Fertility rate vs life expectancy in selected countries (2010).' + ' X=Life Expectancy, Y=Fertility, Bubble size=Population, Bubble color=Region', hAxis: {title: 'Life Expectancy'}, vAxis: {title: 'Fertility Rate'}, bubble: { textStyle: { auraColor: 'none' } } };
<head> <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script> <script type="text/javascript"> google.charts.load("current", {packages:["corechart"]}); google.charts.setOnLoadCallback(drawChart); function drawChart() { var data = google.visualization.arrayToDataTable([ ['ID', 'Life Expectancy', 'Fertility Rate', 'Region', 'Population'], ['CAN', 80.66, 1.67, 'North America', 33739900], ['DEU', 79.84, 1.36, 'Europe', 81902307], ['DNK', 78.6, 1.84, 'Europe', 5523095], ['EGY', 72.73, 2.78, 'Middle East', 79716203], ['GBR', 80.05, 2, 'Europe', 61801570], ['IRN', 72.49, 1.7, 'Middle East', 73137148], ['IRQ', 68.09, 4.77, 'Middle East', 31090763], ['ISR', 81.55, 2.96, 'Middle East', 7485600], ['RUS', 68.6, 1.54, 'Europe', 141850000], ['USA', 78.09, 2.05, 'North America', 307007000] ]); var options = { title: 'Fertility rate vs life expectancy in selected countries (2010).' + ' X=Life Expectancy, Y=Fertility, Bubble size=Population, Bubble color=Region', hAxis: {title: 'Life Expectancy'}, vAxis: {title: 'Fertility Rate'}, bubble: { textStyle: { auraColor: 'none', } } }; var chart = new google.visualization.BubbleChart(document.getElementById('noAura')); chart.draw(data, options); } </script> </head> <body> <div id="noAura" style="width: 900px; height: 500px;"></div> </body> </html>
Loading
The google.charts.load package name is "corechart".
google.charts.load("current", {packages: ["corechart"]});
The visualization's class name is google.visualization.BubbleChart.
var visualization = new google.visualization.BubbleChart(container);
Data Format
Rows: Each row in the table represents a single bubble.
Columns:
| Column 0 | Column 1 | Column 2 | Column 3 (optional) | Column 4 (optional) | |
|---|---|---|---|---|---|
| Purpose: | ID (name) of the bubble | X coordinate | Y coordinate | Either a series ID or a value representing a color on a gradient scale,
        depending on the column type: 
 | Size; values in this column are mapped to actual pixel values using the sizeAxisoption. | 
| Data Type: | string | number | number | string or number | number | 
Configuration Options
| Name | |
|---|---|
| animation.duration | The duration of the animation, in milliseconds. For details, see the animation documentation. Type: number Default: 0 | 
| animation.easing | The easing function applied to the animation. The following options are available: 
 Type: string Default: 'linear' | 
| animation.startup | 
      Determines if the chart will animate on the initial draw. If  Type: boolean Default false | 
| axisTitlesPosition | Where to place the axis titles, compared to the chart area. Supported values: 
 Type: string Default: 'out' | 
| backgroundColor | 
      The background color for the main area of the chart. Can be either a simple HTML color string,
      for example:  Type: string or object Default: 'white' | 
| backgroundColor.stroke | The color of the chart border, as an HTML color string. Type: string Default: '#666' | 
| backgroundColor.strokeWidth | The border width, in pixels. Type: number Default: 0 | 
| backgroundColor.fill | The chart fill color, as an HTML color string. Type: string Default: 'white' | 
| bubble | An object with members to configure the visual properties of the bubbles. Type: object Default: null | 
| bubble.opacity | The opacity of the bubbles, where 0 is fully transparent and 1 is fully opaque. Type: number between 0.0 and 1.0 Default: 0.8 | 
| bubble.stroke | The color of the bubbles' stroke. Type: string Default: '#ccc' | 
| bubble.textStyle | An object that specifies the bubble text style. The object has this format: {color: <string>, fontName: <string>, fontSize: <number>}
        The  Type: object 
        Default:
         
          {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
         | 
| chartArea | 
      An object with members to configure the placement and size of the chart area (where the chart
      itself is drawn, excluding axis and legends). Two formats are supported: a number, or a
      number followed by %. A simple number is a value in pixels; a number followed by % is a
      percentage. Example:  Type: object Default: null | 
| chartArea.backgroundColor | 
      Chart area background color. When a string is used, it can be either a hex string
      (e.g., '#fdc') or an English color name. When an object is used, the following properties can
      be provided:
     
 Type: string or object Default: 'white' | 
| chartArea.left | How far to draw the chart from the left border. Type: number or string Default: auto | 
| chartArea.top | How far to draw the chart from the top border. Type: number or string Default: auto | 
| chartArea.width | Chart area width. Type: number or string Default: auto | 
| chartArea.height | Chart area height. Type: number or string Default: auto | 
| colors | 
      The colors to use for the chart elements. An array of strings, where each element is an HTML
      color string, for example:  Type: Array of strings Default: default colors | 
| colorAxis | An object that specifies a mapping between color column values and colors or a gradient scale. To specify properties of this object, you can use object literal notation, as shown here:  {minValue: 0,  colors: ['#FF0000', '#00FF00']}Type: object Default: null | 
| colorAxis.minValue | 
      If present, specifies a minimum value for chart color data. Color data values of this value
      and lower will be rendered as the first color in the  Type: number Default: Minimum value of color column in chart data | 
| colorAxis.maxValue | 
      If present, specifies a maximum value for chart color data. Color data values of this value
      and higher will be rendered as the last color in the  Type: number Default: Maximum value of color column in chart data | 
| colorAxis.values | 
      If present, controls how values are associated with colors. Each value is associated with the
      corresponding color in the  Type: array of numbers Default: null | 
| colorAxis.colors | 
      Colors to assign to values in the visualization. An array of strings, where each element is
      an HTML color string, for example:  Type: array of color strings Default: null | 
| colorAxis.legend | An object that specifies the style of the gradient color legend. Type: object Default: null | 
| colorAxis.legend.position | Position of the legend. Can be one of the following: 
 Type: object Default: 'top' | 
| colorAxis.legend.textStyle | An object that specifies the legend text style. The object has this format: {color: <string>, fontName: <string>, fontSize: <number>}
        The  Type: object 
        Default:
         
          {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
         | 
| colorAxis.legend.numberFormat | 
        A format string for numeric labels. This is a subset of the
        
          ICU pattern set
        .
        For instance,  Type: string Default: auto | 
| enableInteractivity | Whether the chart throws user-based events or reacts to user interaction. If false, the chart will not throw 'select' or other interaction-based events (but will throw ready or error events), and will not display hovertext or otherwise change depending on user input. Type: boolean Default: true | 
| explorer | 
      The  This feature is experimental and may change in future releases. Note: The explorer only works with continuous axes (such as numbers or dates). Type: object Default: null | 
| explorer.actions | The Google Charts explorer supports three actions: 
 Type: Array of strings Default: ['dragToPan', 'rightClickToReset'] | 
| explorer.axis | 
      By default, users can pan both horizontally and vertically when the  Type: string Default: both horizontal and vertical panning | 
| explorer.keepInBounds | 
      By default, users can pan all around, regardless of where the data is. To ensure that users
      don't pan beyond the original chart, use  Type: boolean Default: false | 
| explorer.maxZoomIn | 
      The maximum that the explorer can zoom in. By default, users will be able to zoom in enough
      that they'll see only 25% of the original view. Setting
       Type: number Default: 0.25 | 
| explorer.maxZoomOut | 
      The maximum that the explorer can zoom out. By default, users will be able to zoom out far
      enough that the chart will take up only 1/4 of the available space. Setting
       Type: number Default: 4 | 
| explorer.zoomDelta | 
      When users zoom in or out,  Type: number Default: 1.5 | 
| fontSize | The default font size, in pixels, of all text in the chart. You can override this using properties for specific chart elements. Type: number Default: automatic | 
| fontName | The default font face for all text in the chart. You can override this using properties for specific chart elements. Type: string Default: 'Arial' | 
| forceIFrame | Draws the chart inside an inline frame. (Note that on IE8, this option is ignored; all IE8 charts are drawn in i-frames.) Type: boolean Default: false | 
| hAxis | An object with members to configure various horizontal axis elements. To specify properties of this object, you can use object literal notation, as shown here: 
{
  title: 'Hello',
  titleTextStyle: {
    color: '#FF0000'
  }
}
    Type: object Default: null | 
| hAxis.baseline | The baseline for the horizontal axis. Type: number Default: automatic | 
| hAxis.baselineColor | 
      The color of the baseline for the horizontal axis. Can be any HTML color string, for example:
       Type: number Default: 'black' | 
| hAxis.direction | 
      The direction in which the values along the horizontal axis grow. Specify  Type: 1 or -1 Default: 1 | 
| hAxis.format | 
      A format string for numeric axis labels. This is a subset of the
      
        ICU pattern set
      . For instance,  
 The actual formatting applied to the label is derived from the locale the API has been loaded with. For more details, see loading charts with a specific locale . 
      In computing tick values and gridlines, several alternative
      combinations of all the relevant gridline
      options will be considered and alternatives will be rejected if the
      formatted tick labels would be duplicated or overlap.
      So you can specify  Type: string Default: auto | 
| hAxis.gridlines | An object with properties to configure the gridlines on the horizontal axis. Note that horizontal axis gridlines are drawn vertically. To specify properties of this object, you can use object literal notation, as shown here: {color: '#333', minSpacing: 20}Type: object Default: null | 
| hAxis.gridlines.color | The color of the horizontal gridlines inside the chart area. Specify a valid HTML color string. Type: string Default: '#CCC' | 
| hAxis.gridlines.count | 
      The approximate number of horizontal gridlines inside the chart area.
      If you specify a positive number for  Type: number Default: -1 | 
| hAxis.gridlines.units | Overrides the default format for various aspects of date/datetime/timeofday data types when used with chart computed gridlines. Allows formatting for years, months, days, hours, minutes, seconds, and milliseconds. General format is: 
gridlines: {
  units: {
    years: {format: [/*format strings here*/]},
    months: {format: [/*format strings here*/]},
    days: {format: [/*format strings here*/]}
    hours: {format: [/*format strings here*/]}
    minutes: {format: [/*format strings here*/]}
    seconds: {format: [/*format strings here*/]},
    milliseconds: {format: [/*format strings here*/]},
  }
}
    Additional information can be found in Dates and Times. Type: object Default: null | 
| hAxis.minorGridlines | An object with members to configure the minor gridlines on the horizontal axis, similar to the hAxis.gridlines option. Type: object Default: null | 
| hAxis.minorGridlines.color | The color of the horizontal minor gridlines inside the chart area. Specify a valid HTML color string. Type: string Default: A blend of the gridline and background colors | 
| hAxis.minorGridlines.count | The  Type: number Default:1 | 
| hAxis.minorGridlines.units | Overrides the default format for various aspects of date/datetime/timeofday data types when used with chart computed minorGridlines. Allows formatting for years, months, days, hours, minutes, seconds, and milliseconds. General format is: 
gridlines: {
  units: {
    years: {format: [/*format strings here*/]},
    months: {format: [/*format strings here*/]},
    days: {format: [/*format strings here*/]}
    hours: {format: [/*format strings here*/]}
    minutes: {format: [/*format strings here*/]}
    seconds: {format: [/*format strings here*/]},
    milliseconds: {format: [/*format strings here*/]},
  }
}
    Additional information can be found in Dates and Times. Type: object Default: null | 
| hAxis.logScale | 
       Type: boolean Default: false | 
| hAxis.scaleType | 
       
 Type: string Default: null | 
| hAxis.textPosition | Position of the horizontal axis text, relative to the chart area. Supported values: 'out', 'in', 'none'. Type: string Default: 'out' | 
| hAxis.textStyle | An object that specifies the horizontal axis text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| hAxis.ticks | 
      Replaces the automatically generated X-axis ticks with the specified array. Each element of
      the array should be either a valid tick value (such as a number, date, datetime, or
      timeofday), or an object. If it's an object, it should have a  
      The viewWindow will be automatically expanded to
      include the min and max ticks unless you specify a
       Examples: 
 Type: Array of elements Default: auto | 
| hAxis.title | 
       Type: string Default: null | 
| hAxis.titleTextStyle | An object that specifies the horizontal axis title text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| hAxis.maxValue | 
      Moves the max value of the horizontal axis to the specified value; this will be rightward in
      most charts. Ignored if this is set to a value smaller than the maximum x-value of the data.
       Type: number Default: automatic | 
| hAxis.minValue | 
      Moves the min value of the horizontal axis to the specified value; this will be leftward in
      most charts. Ignored if this is set to a value greater than the minimum x-value of the data.
       Type: number Default: automatic | 
| hAxis.viewWindowMode | Specifies how to scale the horizontal axis to render the values within the chart area. The following string values are supported: 
 Type: string 
      Default:
      Equivalent to 'pretty', but  haxis.viewWindow.minandhaxis.viewWindow.maxtake precedence if used. | 
| hAxis.viewWindow | Specifies the cropping range of the horizontal axis. Type: object Default: null | 
| hAxis.viewWindow.max | The maximum horizontal data value to render. Ignored when  Type: number Default: auto | 
| hAxis.viewWindow.min | The minimum horizontal data value to render. Ignored when  Type: number Default: auto | 
| height | Height of the chart, in pixels. Type: number Default: height of the containing element | 
| legend | An object with members to configure various aspects of the legend. To specify properties of this object, you can use object literal notation, as shown here: {position: 'top', textStyle: {color: 'blue', fontSize: 16}}Type: object Default: null | 
| legend.alignment | Alignment of the legend. Can be one of the following: 
 Start, center, and end are relative to the style -- vertical or horizontal -- of the legend. For example, in a 'right' legend, 'start' and 'end' are at the top and bottom, respectively; for a 'top' legend, 'start' and 'end' would be at the left and right of the area, respectively. The default value depends on the legend's position. For 'bottom' legends, the default is 'center'; other legends default to 'start'. Type: string Default: automatic | 
| legend.maxLines | Maximum number of lines in the legend. Set this to a number greater than one to add lines to your legend. Note: The exact logic used to determine the actual number of lines rendered is still in flux. This option currently works only when legend.position is 'top'. Type: number Default: 1 | 
| legend.pageIndex | Initial selected zero-based page index of the legend. Type: number Default: 0 | 
| legend.position | Position of the legend. Can be one of the following: 
 Type: string Default: 'right' | 
| legend.textStyle | An object that specifies the legend text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| selectionMode | 
      When  Type: string Default: 'single' | 
| series | An object of objects, where the keys are series names (the values in the Color column) and each object describing the format of the corresponding series in the chart. If a series or a value is not specified, the global value will be used. Each object supports the following properties: 
 series: {'Europe': {color: 'green'}}Type: Object with nested objects Default: {} | 
| sizeAxis | An object with members to configure how values are associated with bubble size. To specify properties of this object, you can use object literal notation, as shown here:  {minValue: 0,  maxSize: 20}Type: object Default: null | 
| sizeAxis.maxSize | Maximum radius of the largest possible bubble, in pixels. Type: number Default: 30 | 
| sizeAxis.maxValue | 
      The size value (as appears in the chart data) to be mapped to  Type: number Default: Maximum value of size column in chart data | 
| sizeAxis.minSize | Mininum radius of the smallest possible bubble, in pixels. Type: number Default: 5 | 
| sizeAxis.minValue | 
      The size value (as appears in the chart data) to be mapped to  Type: number Default: Minimum value of size column in chart data | 
| sortBubblesBySize | If true, sorts the bubbles by size so the smaller bubbles appear above the larger bubbles. If false, bubbles are sorted according to their order in the DataTable. Type: boolean Default: true | 
| theme | A theme is a set of predefined option values that work together to achieve a specific chart behavior or visual effect. Currently only one theme is available: 
 Type: string Default: null | 
| title | Text to display above the chart. Type: string Default: no title | 
| titlePosition | Where to place the chart title, compared to the chart area. Supported values: 
 Type: string Default: 'out' | 
| titleTextStyle | An object that specifies the title text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| tooltip | An object with members to configure various tooltip elements. To specify properties of this object, you can use object literal notation, as shown here: {textStyle: {color: '#FF0000'}, showColorCode: true}Type: object Default: null | 
| tooltip.isHtml | If set to true, use HTML-rendered (rather than SVG-rendered) tooltips. See Customizing Tooltip Content for more details. Note: customization of the HTML tooltip content via the tooltip column data role is not supported by the Bubble Chart visualization. Type: boolean Default: false | 
| tooltip.textStyle | An object that specifies the tooltip text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| tooltip.trigger | The user interaction that causes the tooltip to be displayed: 
 Type: string Default: 'focus' | 
| vAxis | An object with members to configure various vertical axis elements. To specify properties of this object, you can use object literal notation, as shown here: {title: 'Hello', titleTextStyle: {color: '#FF0000'}}Type: object Default: null | 
| vAxis.baseline | 
       Type: number Default: automatic | 
| vAxis.baselineColor | 
      Specifies the color of the baseline for the vertical axis. Can be any HTML color string, for
      example:  Type: number Default: 'black' | 
| vAxis.direction | 
      The direction in which the values along the vertical axis grow.  By default, low values
      are on the bottom of the chart.  Specify  Type: 1 or -1 Default: 1 | 
| vAxis.format | 
      A format string for numeric axis labels. This is a subset of the
      
        ICU pattern set
      .
      For instance,  
 The actual formatting applied to the label is derived from the locale the API has been loaded with. For more details, see loading charts with a specific locale . 
      In computing tick values and gridlines, several alternative
      combinations of all the relevant gridline
      options will be considered and alternatives will be rejected if the
      formatted tick labels would be duplicated or overlap.
      So you can specify  Type: string Default: auto | 
| vAxis.gridlines | An object with members to configure the gridlines on the vertical axis. Note that vertical axis gridlines are drawn horizontally. To specify properties of this object, you can use object literal notation, as shown here: {color: '#333', minSpacing: 20}Type: object Default: null | 
| vAxis.gridlines.color | The color of the vertical gridlines inside the chart area. Specify a valid HTML color string. Type: string Default: '#CCC' | 
| vAxis.gridlines.count | 
      The approximate number of horizontal gridlines inside the chart area.
      If you specify a positive number for  Type: number Default: -1 | 
| vAxis.gridlines.units | Overrides the default format for various aspects of date/datetime/timeofday data types when used with chart computed gridlines. Allows formatting for years, months, days, hours, minutes, seconds, and milliseconds. General format is: 
gridlines: {
  units: {
    years: {format: [/*format strings here*/]},
    months: {format: [/*format strings here*/]},
    days: {format: [/*format strings here*/]},
    hours: {format: [/*format strings here*/]},
    minutes: {format: [/*format strings here*/]},
    seconds: {format: [/*format strings here*/]},
    milliseconds: {format: [/*format strings here*/]}
  }
}
    Additional information can be found in Dates and Times. Type: object Default: null | 
| vAxis.minorGridlines | An object with members to configure the minor gridlines on the vertical axis, similar to the vAxis.gridlines option. Type: object Default: null | 
| vAxis.minorGridlines.color | The color of the vertical minor gridlines inside the chart area. Specify a valid HTML color string. Type: string Default: A blend of the gridline and background colors | 
| vAxis.minorGridlines.count | The minorGridlines.count option is mostly deprecated, except for disabling minor gridlines by setting the count to 0. The number of minor gridlines depends on the interval between major gridlines (see vAxis.gridlines.interval) and the minimum required space (see vAxis.minorGridlines.minSpacing). Type: number Default: 1 | 
| vAxis.minorGridlines.units | Overrides the default format for various aspects of date/datetime/timeofday data types when used with chart computed minorGridlines. Allows formatting for years, months, days, hours, minutes, seconds, and milliseconds. General format is: 
gridlines: {
  units: {
    years: {format: [/*format strings here*/]},
    months: {format: [/*format strings here*/]},
    days: {format: [/*format strings here*/]}
    hours: {format: [/*format strings here*/]}
    minutes: {format: [/*format strings here*/]}
    seconds: {format: [/*format strings here*/]},
    milliseconds: {format: [/*format strings here*/]},
  }
}
    Additional information can be found in Dates and Times. Type: object Default: null | 
| vAxis.logScale | If true, makes the vertical axis a logarithmic scale. Note: All values must be positive. Type: boolean Default: false | 
| vAxis.scaleType | 
       
 Type: string Default: null | 
| vAxis.textPosition | Position of the vertical axis text, relative to the chart area. Supported values: 'out', 'in', 'none'. Type: string Default: 'out' | 
| vAxis.textStyle | An object that specifies the vertical axis text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
    
      The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| vAxis.ticks | 
      Replaces the automatically generated Y-axis ticks with the specified array. Each element of
      the array should be either a valid tick value (such as a number, date, datetime, or
      timeofday), or an object. If it's an object, it should have a  
      The viewWindow will be automatically expanded to
      include the min and max ticks unless you specify a
       Examples: 
 Type: Array of elements Default: auto | 
| vAxis.title | 
 Type: string Default: no title | 
| vAxis.titleTextStyle | An object that specifies the vertical axis title text style. The object has this format: 
{ color: <string>,
  fontName: <string>,
  fontSize: <number>,
  bold: <boolean>,
  italic: <boolean> }
  
    The  Type: object 
      Default:
       
        {color: 'black', fontName: <global-font-name>, fontSize: <global-font-size>}
       | 
| vAxis.maxValue | 
      Moves the max value of the vertical axis to the specified value; this will be upward in most
      charts. Ignored if this is set to a value smaller than the maximum y-value of the data.
       Type: number Default: automatic | 
| vAxis.minValue | 
      Moves the min value of the vertical axis to the specified value; this will be downward in
      most charts. Ignored if this is set to a value greater than the minimum y-value of the data.
       Type: number Default: null | 
| vAxis.viewWindowMode | Specifies how to scale the vertical axis to render the values within the chart area. The following string values are supported: 
 Type: string 
      Default:
      Equivalent to 'pretty', but  vaxis.viewWindow.minandvaxis.viewWindow.maxtake precedence if used. | 
| vAxis.viewWindow | Specifies the cropping range of the vertical axis. Type: object Default: null | 
| vAxis.viewWindow.max | The maximum vertical data value to render. Ignored when  Type: number Default: auto | 
| vAxis.viewWindow.min | The minimum vertical data value to render. Ignored when  Type: number Default: auto | 
| width | Width of the chart, in pixels. Type: number Default: width of the containing element | 
Methods
| Method | |
|---|---|
| draw(data, options) | 
      Draws the chart. The chart accepts further method calls only after the
       Return Type: none | 
| getAction(actionID) | Returns the tooltip action object with the requested  Return Type: object | 
| getBoundingBox(id) | 
      Returns an object containing the left, top, width, and height of chart element
       
 Values are relative to the container of the chart. Call this after the chart is drawn. Return Type: object | 
| getChartAreaBoundingBox() | Returns an object containing the left, top, width, and height of the chart content (i.e., excluding labels and legend): 
 Values are relative to the container of the chart. Call this after the chart is drawn. Return Type: object | 
| getChartLayoutInterface() | Returns an object containing information about the onscreen placement of the chart and its elements. The following methods can be called on the returned object: 
 Call this after the chart is drawn. Return Type: object | 
| getHAxisValue(xPosition, optional_axis_index) | 
      Returns the horizontal data value at  Example:  Call this after the chart is drawn. Return Type: number | 
| getImageURI() | Returns the chart serialized as an image URI. Call this after the chart is drawn. See Printing PNG Charts. Return Type: string | 
| getSelection() | 
      Returns an array of the selected chart entities.
    
      Selectable entities are bubbles.
    
    
    
      For this chart, only one entity can be selected at any given moment.
    
      
         Return Type: Array of selection elements | 
| getVAxisValue(yPosition, optional_axis_index) | 
      Returns the vertical data value at  Example:  Call this after the chart is drawn. Return Type: number | 
| getXLocation(dataValue, optional_axis_index) | 
      Returns the pixel x-coordinate of  Example:  Call this after the chart is drawn. Return Type: number | 
| getYLocation(dataValue, optional_axis_index) | 
      Returns the pixel y-coordinate of  Example:  Call this after the chart is drawn. Return Type: number | 
| removeAction(actionID) | Removes the tooltip action with the requested  Return Type:  none | 
| setAction(action) | Sets a tooltip action to be executed when the user clicks on the action text. 
      The  
      Any and all tooltip actions should be set prior to calling the chart's  Return Type:  none | 
| setSelection() | 
      Selects the specified chart entities. Cancels any previous selection.
    
      Selectable entities are bubbles.
    
    
    
      For this chart, only one entity can be selected at a time.
    
      
         Return Type: none | 
| clearChart() | Clears the chart, and releases all of its allocated resources. Return Type: none | 
Events
For more information on how to use these events, see Basic Interactivity, Handling Events, and Firing Events.
| Name | |
|---|---|
| animationfinish | Fired when transition animation is complete. Properties: none | 
| click | Fired when the user clicks inside the chart. Can be used to identify when the title, data elements, legend entries, axes, gridlines, or labels are clicked. Properties: targetID | 
| error | Fired when an error occurs when attempting to render the chart. Properties: id, message | 
| legendpagination | Fired when the user clicks legend pagination arrows. Passes back the current legend zero-based page index and the total number of pages. Properties: currentPageIndex, totalPages | 
| onmouseover | Fired when the user mouses over a visual entity. Passes back the row and column indices of the corresponding data table element. A bubble correlates to a row in the data table (column index is null). Properties: row, column | 
| onmouseout | Fired when the user mouses away from a visual entity. Passes back the row and column indices of the corresponding data table element. A bubble correlates to a row in the data table (column index is null). Properties: row, column | 
| ready | 
      The chart is ready for external method calls. If you want to interact with the chart, and
      call methods after you draw it, you should set up a listener for this event before you
      call the  Properties: none | 
| select | 
      Fired when the user clicks a visual entity. To learn what has been selected, call
       Properties: none | 
Data Policy
All code and data are processed and rendered in the browser. No data is sent to any server.