Top
You are looking at an outdated 7.7.0 version of this document. Switch to the 8.0.1 version to see the up to date information.

class anychart.charts.Map Improve this Doc

Extends: anychart.core.SeparateChart

AnyChart Map class.

Methods Overview

Specific settings
getType()Returns chart type.
unboundRegions()Region's settings, that don't linked to anything regions.
Chart Coloring
hatchFillPalette()Hatch fill palette.
markerPalette()Markers palette.
palette()Map palette.
Chart Controls
colorRange()Color range settings.
Data
geoData()Geo data settings.
Interactivity
allowPointsSelect()Selected state of the map points
Series
choropleth()Creates choropleth series.
getSeries()Getter for the series by index.

Methods Description

allowPointsSelect

Getter for the current selected state of the map points.

Returns:

boolean - The current selected state of the points.

Try it:

Allows to select points of the Map.

Params:

Name Type Default Description
value boolean
true
Allow or not.

Returns:

anychart.charts.Map - Self instance for method chaining.

Try it:

choropleth

Creates choropleth series.

Params:

Name Type Description
data anychart.data.View | anychart.data.Set | Array | string Series data as SVG, SVGString, GeoJSON or MapNameString.
csvSettings Object.<string, (string|boolean)> If CSV string is passed, you can pass CSV parser settings here as a hash map.

Returns:

anychart.core.map.series.Choropleth - An instance of class for method chaining.

Try it:

colorRange

Getter for the current color range.

Returns:

anychart.core.ui.ColorRange - The current color range.

Try it:

Setter for the color range.

Params:

Name Type Description
value anychart.core.ui.ColorRange | Object Chart marker palette settings to set.

Returns:

anychart.charts.Map - Self instance for method chaining.

Try it:

geoData

Getter for the current geo data.

Returns:

Node string Object - The current geo data.
Setter for the geo data.

Params:

Name Type Description
data Node | string | Object Map data as SVG, SVGString, GeoJSON or MapNameString.

Returns:

Node string Object - Passed geo data.

Try it:

getSeries

Getter for the series by index.

Params:

Name Type Description
index number Series index.

Returns:

anychart.core.map.series.Base - Self instance for method chaining.

Try it:

getType

Returns chart type.

Returns:

anychart.enums.ChartTypes - Current chart type.

Try it:

hatchFillPalette

Getter for the current map hatch fill palette settings.

Returns:

anychart.palettes.HatchFills - The current chart hatch fill palette.
Setter for map hatch fill palette settings.

Params:

Name Type Description
value Array.<anychart.graphics.vector.HatchFill.HatchFillType> | Object | anychart.palettes.HatchFills Chart hatch fill palette settings to set.

Returns:

anychart.charts.Map - Self instance for method chaining.

Try it:

markerPalette

Getter for map markers palette settings.

Returns:

anychart.palettes.Markers - The current map markers palette.
Setter for map markers palette settings.

Params:

Name Type Description
value anychart.palettes.Markers | Object | Array.<anychart.enums.MarkerType> Map marker palette settings to set.

Returns:

anychart.charts.Map - Self instance for method chaining.

Try it:

palette

Getter for the current map palette.
Setter for the current map palette.

Params:

Name Type Description
value anychart.palettes.RangeColors | anychart.palettes.DistinctColors | Object | Array.<string> Color palette instance.

Returns:

anychart.charts.Map - Self instance for method chaining.

unboundRegions

Getter for the current settings for regions, that don't linked to anything regions.

Returns:

anychart.core.utils.UnboundRegionsSettings - The current settings for regions.

Try it:

Setter for the settings for regions, that don't linked to anything regions.

Params:

Name Type Default Description
value Object | boolean
true
Settings object or boolean value like enabled state.

Returns:

anychart.charts.Map - Self instance for method chaining.