Jump to content

Graph high dimensional data in 2D graph


Recommended Posts

Here is a graph I made recently, which shows particle number (symbol), material (broad color family), measurement location (exact color), amplitude (X axis) and phase (Y axis).  That's five dimensions in a 2D graph!  There are some obvious limitations.  For instance, there are only 16 symbols, so whatever you're representing by choice of symbol better not have more than 16 categories.  And there are only so many colors, especially if you want them all to be ordered in a spectrum from red to violet.  It gets worse when you try to have "broad color family" like I do here with reddish colors for aluminum and bluish for titanium, because the obvious logical thing to do is to skip over some shades in between the families, reducing the total number of available colors.


What other options should I consider?  How do you do it?  I don't usually use 3D graphs because (a) they're harder to work with and (b) when I create a report for management, they like to have 2D images they can print out, or view without needing Labview on their computer.

I'm attaching two VIs I use to create color spectra for my graphs.  I use colors_darken_lighten to darken plots for a white background.  To skip over colors, I obtained 6 colors in my spectrum and reshaped the array to two-by-three, then indexed by measurement location to get the first two colors from each broad color family.




Edited by torekp
show graph as .png
Link to comment

If some of your "dimensions" are just A vs. B (e.g. 50 vs. 220, Al vs. Ti like in what you show), perhaps plotting each group in a different panel and juxtaposing them may convey better the information than a single plot with too many similar looking symbols.

Indeed the symbol variety in LV plots is nothing impressing. Other plotting packages have many more options as for shapes (e.g clubs, diamonds, ducks, broccoli), hatchings, and whatnot.

One additional style parameter which you could use to differentiate sets on the same plot in LV, could be symbol size (Line Width). Of course useful only where you have two or three possible classes, not for a continuous range.

Link to comment

I dont care how many symbol varieties you have, I personally have difficulty reading a 2d graph with more than a few (for the purposes of your graph, lets say 4) groups of data on it. I mean I know its necessary sometimes to show more, but in your case, what is the user of the graph going to look at? Do they really care about all of those variables at the same time, or as mentioned could you divide it into 1 graph per material, or 1 graph per particle number.

If you do need to show all the data at once, one of the graphs in this package may help:
It uses the python matplotlib library which is intended as a clone of matlab's plots which are better than labview's really nothing special compared to the glory of the labview graph control, down with matlab.

Some (different) people have used mscharts with some success but I've never personally looked into it.

Edited by smithd
  • Like 1
Link to comment

Thanks guys!  I'm downloading the matlab style package now.

The primary user is me, actually, and I chose my scheme so that it's easy to ignore everything but color, which groups things nicely.  It is a little more convenient for me to graph every particle on one graph, but maybe it would make better sense to have two graphs, one per location.  Good idea.  Thanks again.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site, you agree to our Terms of Use.