Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

85
Views
highcharts build map with a set of values and display another set of values as labels

I have a set of data like this :

var data = [
    ['gl', 2584],
    ['sh', 100201],
    ['bu', 2025],
    ['lk', 30336],
    ['as', 41225],
    ['dk', 500],
    ['fo', 655225],
    ['gu', 7555],
    ['mp', 85454],
    ['um', 90147],
    ['us', 10087]]

I am normalizing the above array into the range of [0,1] to give different colours to High charts world map based on following conditions.

0.0-0.15 Green
0.15-0.30 yellow
0.30-0.60 orange
0.60-1 red

I want to set colours based on normalized array but show the labels from above data array. How can I do this ?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

You can define an array of stops value with each color. Take a look at this demo: https://jsfiddle.net/BlackLabel/gbnd36zr/

  colorAxis: {
    min: 0,
    stops: [
      [0.15, 'green'],
      [0.3, 'yellow'],
      [0.6, 'orange'],
      [1, 'red']
    ]
  },

API: https://api.highcharts.com/highmaps/colorAxis.stops

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!