Skip to content
All library documents

Building Color Scales, Gradients, and Market Heatmaps in MQL5

Article MQL5 code base

Summary

This document introduces an MQL5 example for presenting market data with color scales, gradients, and heatmaps. It uses the RGB color model, which makes it possible to perform mathematical operations on color values, and mentions a standard conversion function for turning color strings into values. The example offers three display styles: a scale, a gradient, or a heatmap.

The suggested use is to compare daily percentage changes across instruments shown in Market Watch. The author recommends displaying at least five symbols and keeping the set to roughly twenty to twenty-five so the visualization fits on screen. These are layout suggestions, not evidence that the display improves trading decisions. The document provides no formulas for mapping returns to colors, performance results, or details on data handling, so it serves mainly as a visualization implementation concept.

Key ideas

  • MQL5 can display market values using color scales, gradients, or heatmaps.
  • The example uses RGB values to support mathematical color operations.
  • The proposed use is to view daily percentage changes across Market Watch instruments.
  • The suggested symbol count balances comparison breadth with available screen space.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.