Announcement: All noncommercial projects registered to use Earth Engine before April 15, 2025 must verify noncommercial eligibility to maintain access. If you have not verified by September 26, 2025, your access may be on hold.
ui.Chart.setChartType
Stay organized with collections
Save and categorize content based on your preferences.
AI-generated Key Takeaways
Chart.setChartType sets the chart type of a ui.Chart instance.
This method returns the ui.Chart instance, allowing for method chaining.
The chartType argument is a String specifying the desired chart type, such as 'ScatterChart', 'LineChart', or 'ColumnChart'.
A variety of chart types can be set using this method, including Scatter, Line, Column, Bar, Pie, Area, and Table charts.
Sets the chartType of this chart.
Returns this chart.
Usage
Returns
Chart.setChartType(chartType)
ui.Chart
Argument
Type
Details
this: ui.chart
ui.Chart
The ui.Chart instance.
chartType
String
The chart type; e.g 'ScatterChart', 'LineChart', and 'ColumnChart'. For the complete list of charts, see: https://developers.google.com/chart/interactive/docs/gallery
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2023-10-06 UTC."],[],["The `setChartType` method sets the type of a `ui.Chart` instance and returns the modified chart. It accepts a string argument (`chartType`) that specifies the desired chart type, such as 'ScatterChart', 'LineChart', or 'ColumnChart'. A data table is used to exemplify different chart types. Various chart examples include scatter, line, column, bar, pie, area and tables, and the complete list of chart types is found in the provided url.\n"]]