简体   繁体   中英

Algorithm to “smooth out” data values for visualization

I'm reading some data for countries around the world and am playing with Google's visualization gadgets, in particular the map visualizations . The problem is, that the US always comes out way in front. While most countries have values between 1 and 50, the US consistently has a value of 2000+. Which means in the visualization, it's hard to tell the difference between all the "small countries", as they all get about the same shade of pale green, while the US always is a fat dark green.

I don't particularly care about the accuracy of the visualization, so I'd like to smooth out or average out the values a bit so that there's a visible difference between the very-low, low and not-so-low countries. What's a good algorithm to do that?

A pretty simple problem, but I'm not a math guy at all. ^_^;;

How about displaying data on a logarithmic scale. That way a value of 10 translates to 1, a value of 100 translates to 2, 1000 translates to 3 and so on.

Log scales are an option if , in general there is a magnitude order of difference between most of the important data points.

However, if your distribution is bimodal - you are better of normalizing then log crushing your data.

To do this, you must find a parameter that correlates to the united states 2000+ ( GDP maybe?) and normalize all data points to the regional value of this number . Thn you will see the precise differences you are interested in an intuitive color map.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM