Hide Table of Contents
esri/dijit/util
esri/layer/pixelFilters
esri/process
esri/support
esri/workers
Object: esri/styles/relationship

require(["esri/styles/relationship"], function(esriStylesRelationship) { /* code goes here */ });

Description

(Added at v3.25)
This module contains a collection of color schemes suitable for creating relationship (or bivariate choropleth) visualizations.

Samples

Search for samples that use this class.

Methods

NameReturn typeSummary
getAvailableThemes(basemap)Object[]Returns themes available for the given basemap.
getSchemes(params)ObjectReturns the primary and secondary color schemes for the given theme, basemap, and geometry type.
Method Details

getAvailableThemes(basemap)

Returns themes available for the given basemap. The theme is required for getting the relevant color schemes from the getSchemes() method.
Return type: Object[]
Parameters:
<String> basemap Required Specifies the basemap name if you only want themes applicable to a specific basemap, for example: streets, gray, topo, terrain, national-geographic, oceans, osm, satellite, hybrid, dark-gray.
Sample:

// returns an array of themes pertaining to the streets basemap
esriStylesRelationship.getAvailableThemes("streets");

getSchemes(params)

Returns the primary and secondary color schemes for the given theme, basemap, and geometry type. One of the returned schemes may be used as a parameter to the smartMapping.createRelationshipRenderer() method. See esriStylesChoropleth.getSchemes() for details about the return object.
Return type: Object
Parameters:
<Object> params Required See the params Object Specifications table below for a description of the method parameters.
Object Specifications:
<params>
<String> basemap Required Name of the basemap. Some example values include: streets, gray, topo, terrain, national-geographic, oceans, osm, satellite, hybrid, dark-gray.
<String> geometryType Required Geometry type of features in the relevant dataset. Supported types: "point", "line", "polygon".
<String> theme Required Name of the theme. The only supported value is "default".
Show Modal