Color Mapper User Guide

更新时间:
复制 MD 格式

The color mapper lets you configure the mapping between colors and data values in a widget. It provides over ten built-in color templates and supports custom colors and values to meet your specific needs. This topic uses an example to demonstrate how to configure scatter point colors for the vector scatter layer of a Basic Plain Map 3.0 widget.

Configuration instructions

When you configure scatter point colors for a map sub-widget, you can adjust the colors using one of two methods.

  • Method 1: Click the 关闭颜色映射 icon to the left of the Scatter Color configuration item to disable color mapping. When the Enable Visual Mapping tooltip appears on hover, you can use the color picker to set a single custom color.image

  • Method 2: Click the 打开状态 icon to the left of the Scatter Color configuration item to enable color mapping. When the Close Visual Mapping tooltip is displayed on hover, you can use the color mapper to configure multiple colors for the scatter points based on a data-driven mapping.image

Features

Feature

Description

Switch mapping colors in the collapsed panel

When the color mapper is collapsed, you can click the color display bar to open the multi-color template panel. The top row shows the current mapping result. Multiple color templates are displayed below it. You can click a color bar within a template to quickly switch the mapping colors.image

Configure mapping details in the expanded panel

When the color mapper is expanded, the system automatically reads the data and maps it to colors. You can configure the following mapping details.image

  • Mapping type: The type of data-to-color mapping. The options are Categorical, Continuous, and Quantized. For more information, see Mapping types.

  • Color template: You can click the color template bar to open the multi-color template panel and quickly switch the data mapping colors. After you select a color template, you can click a color in the mapping list below. Then, you can use the color picker to change the color or enter a custom color value.

    Note

    You can click the 钉住图标 icon to the right of a color in the template to pin its value. A pinned color does not change when you switch templates. Unpinned colors change when you switch templates.

    钉住状态

  • Count: Specifies the number of color steps in the template.

  • Reverse order: You can click the 反序 icon to reverse the order of the color mapping list.

  • Abnormal value mapping: You can click the color block to define the mapping for abnormal values, such as undefined, null, and NaN. For more information, see Mapping types.其他值颜色映射

  • Custom mapping: You can turn on this switch to customize the data-to-color mapping.自定义映射

    • Delete a mapping entry: You can click the 垃圾桶图标 icon to the left of a mapping entry to delete the entire row.

    • Set the mapping field: In the input box to the right of a mapping entry, you can enter the data field value that corresponds to the color. Depending on the selected Mapping type, you must enter a text or numeric value.

    • Add a mapping entry: You can click the 添加图标 icon below the color mapping list to add a new mapping entry.

Mapping types

There are three main color mapping types: Categorical, Continuous, and Quantized.

Type

Description

Term Classification

Use this for categorical data, such as names and types, to assign distinct colors. The colors in the palette are highly distinguishable.

Figure 1. Categorical color template style

Figure 2. Example of categorical data名词分类型示例图

Continuous

Use this to assign a continuous color gradient to numeric data. Each value has a one-to-one correspondence with a color in the mapping space.

Figure 3. Continuous color template style数值连续颜色模板样式

Figure 4. Example of continuous data数值连续型示例图

Numeric Partition

This type builds on continuous mapping. It partitions continuous numerical data into intervals. Data within the same interval is assigned the same color. Use quantized mapping to reduce the number of colors and avoid visual clutter.

Figure 5. Quantized color template style数值分区颜色模板样式

Figure 6. Example of quantized data数值分区数据示例