beyond three dimensions
play

Beyond three dimensions Non Cartesian representations R.W. Oldford - PowerPoint PPT Presentation

Beyond three dimensions Non Cartesian representations R.W. Oldford Beyond three dimensions Hey! Im a starfish! Moving from 0 to 1 to 2 to 3 dimensions have all been advances which have required an adjustment in our thinking. It has allowed


  1. Beyond three dimensions Non Cartesian representations R.W. Oldford

  2. Beyond three dimensions Hey! I’m a starfish! Moving from 0 to 1 to 2 to 3 dimensions have all been advances which have required an adjustment in our thinking. It has allowed us to “visualize” more, and more complex, information. Each step requires training.

  3. Cartesian coordinates Cartesian coordinates use orthogonal axes and a grid system to place each point in space. Cartesian coordinates René Descartes (1596-1650) ≥ 4 d? When we have n individual cases each one with its own values for each of p variates, we typically represent the i th case mathematically as a vector x i . The collection of data form a “cloud” of n points in a p -dimensional space. Mathematics doesn’t care what value p > 0 takes. How can a point cloud be visualized in more than three dimensions?

  4. Four dimensional data - example Edgar Anderson’s Iris data: 150 flowers, 50 from each of three different species Iris Virginica Iris Versicolor Iris Setosa Four measurements ◮ sepal width ◮ sepal height ◮ petal width ◮ petal height

  5. Four dimensional data - example Learning from maps, we could use glyphs, especially ones that meaningfully convey the information in the data (provide an ostensive “pictorial form”). Edgar Anderson proposed:

  6. Four dimensional data - example Iris Setosa: Centre glyph is the average.

  7. Four dimensional data - example Iris Versicolor: Centre glyph is the average.

  8. Four dimensional data - example Using averages to compare and locate species Anderson’s real interest lay not in discriminating between species but in whether the middle species (in terms of number of chromosomes and habitat) had relative distance of 1:2 from the two extreme species. This proportion roughly matched the chromosome ratios.

  9. Higher dimensional glyphs Anderson’s nested rectangular glyphs were natural for his problem. They were in a sense actually cartoon versions of the flower parts themselves. So, what might be the most natural glyph for us? We know, for example, that for a variety of reasons including possibly ◮ distinguishing predators and prey, ◮ distinguishing friend from foe ◮ identifying close relations ◮ recognizing mood, reaction ◮ social interaction of all kinds that we have evolved to be very good at recognizing, distinguishing, and reading faces. And that our parts of our brain are “wired” to deal with faces. In 1973 Herman Chernoff suggested we use faces as glyphs .

  10. Chernoff faces Herman Chernoff Constructing a Chernoff face Variate values are assigned to different cartoon face features. A variety of faces have been implemented since Chernoff’s original proposal.

  11. Chernoff faces Original Chernoff Faces, 1973.

  12. Chernoff faces There are a couple of R packages that draw cartoon faces (i.e. variations on Chernoff faces). The first we woll look at is the TeachingDemos package. library (TeachingDemos) The faces2(...) function can accommodate (up to) 18 dimensions as follows: The face features are assigned for columns 1 to (at most) 18 1. Width of center 2. Top vs. Bottom width (height of split) 3. Height of Face 4. Width of top half of face 5. Width of bottom half of face 6. Length of Nose 7. Height of Mouth 8. Curvature of Mouth (abs < 9) 9. Width of Mouth 10. Height of Eyes 11. Distance between Eyes (.5-.9) 12. Angle of Eyes/Eyebrows 13. Circle/Ellipse of Eyes 14. Size of Eyes 15. Position Left/Right of Eyeballs/Eyebrows 16. Height of Eyebrows 17. Angle of Eyebrows 18. Width of Eyebrows

  13. Chernoff faces To demonstrate, we first scale the data to be weetween 0 and 1 for each variate data <- iris[,1 : 4] # the four measurements on Anderson's irises scale01 <- function (x) { xrange <- range (x) (x - min (xrange)) /diff (xrange) } data <- apply (data, 2, scale01) faces2 (data[ c (1, 51, 101), ], which= c (8, 13, 14, 17), scale = "none", nrows=1, ncols=3)

  14. Chernoff faces With the appropriate packages, we can explore how variable these features are library (tkrplot) ## Loading required package: tcltk if ( interactive ()){ tke2 <- rep ( list ( list ('slider',from=0,to=1,init=0.5,resolution=0.1)), 18) names (tke2) <- c ('CenterWidth','TopBottomWidth','FaceHeight','TopWidth', 'BottomWidth','NoseLength','MouthHeight','MouthCurve','MouthWidth', 'EyesHeight','EyesBetween','EyeAngle','EyeShape','EyeSize','EyeballPos', 'EyebrowHeight','EyebrowAngle','EyebrowWidth') tkfun2 <- function (...){ tmpmat <- rbind (Min=0,Adjust= unlist ( list (...)),Max=1) faces2 (tmpmat, scale='none') } tkexamp ( tkfun2, list (tke2), plotloc='left', hscale=2, vscale=2 ) }

  15. Chernoff faces We could choose different variate to feature mappings data <- iris[,1 : 4] # the four measurements on Anderson's irises scale01 <- function (x) { xrange <- range (x) (x - min (xrange)) /diff (xrange) } data <- apply (data, 2, scale01) faces2 (data[ c (1, 51, 101), ], which= c (6, 7, 8, 12), scale = "none", nrows=1, ncols=3)

  16. Chernoff faces For all of the irises (in random order) n <- nrow (data) faces2 (data[ sample (1 : n, n, replace =FALSE), ], which= c (6, 7, 8, 12), nrow=10, ncol=15)

  17. Chernoff faces The olive data (150 randomly selected from 572; 8 dimensions) faces2 (data[ sample (1 :nrow (data), 150, replace = FALSE), ], nrows=10, ncols=15, which= c (1, 2, 3, 4, 6, 7, 8, 12), scale = "none")

  18. Chernoff faces Problems with faces ◮ Eye movements (saccades). ◮ Some facial features are more important than others. ◮ Grouping will depend on which variates are matched to features. ◮ Not so useful for exploratory work, OK (with care) for infographic.

  19. Florence Nightingale’s rose plot Areas (centre to edge) are proportional to value. Time series.

  20. Florence Nightingale’s rose plot E.g. The Atlas of Britain and Northern Ireland, 1963. Note colour used to identify variate. Area proportional to magnitude.

  21. Florence Nightingale’s rose plot There is a function in R called stars(...) which will produce Nightingale’s rose style glyphs. n <- nrow (data) stars (data[ sample (1 : n, n, replace =FALSE), ], nrow=10, ncol=15, main = "Nightingale Roses (almost)", draw.segments=TRUE, cex=1.2)

  22. Florence Nightingale’s rose plot Iris data Nightingale Roses (almost)

  23. Florence Nightingale’s rose plot Olive data Nightingale Roses (almost)

  24. Florence Nightingale’s rose plot Note that our use here is very different from Nightingale’s ◮ Nightingale used overlapping segments (hence the rose) ◮ represented time series (typically strong positive correlation between neighbouring wedges) ◮ i.e. large beside/near large, small beside/near small ◮ very few roses In contrast: ◮ our use is more like that of the 1963 British Atlas example, ◮ no overlapping segments ◮ different variates shown at each wedge ◮ no expectation of correlation’s sign ◮ many “stars” or “roses” ◮ looking to group like looking shapes. Nightingale’s Crimean war could have been represented as stars with 3 segments (one for each cause of death) and a separate star for each month.

  25. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width Axes as equi-angular radii of a circle.

  26. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width Data scaled with dataset’s minimum value at centre, maximum at end (for each variate).

  27. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width One flower. Four measurements.

  28. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width All of the setosa data at once. Correlations?

  29. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width All of the versicolor data at once. Correlations?

  30. Radial Axes Sepal.Width Petal.Length Sepal.Length Petal.Width All of the virginica data at once. Correlations?

  31. Radial Axes Iris Setosa Iris Versicolor Iris Virginica Sepal.Width Sepal.Width Sepal.Width Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Width Petal.Width Petal.Width All three species. Comments?

  32. Radial Axes Iris Setosa Iris Versicolor Iris Virginica Averages Sepal.Width Sepal.Width Sepal.Width Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Width Petal.Width Petal.Width All three species. Comments?

  33. Radial Axes Iris Setosa Iris Versicolor Iris Virginica Altogether Sepal.Width Sepal.Width Sepal.Width Sepal.Width Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Width Petal.Width Petal.Width Petal.Width All three species. Comments?

  34. Radial Axes Averages and Individuals Iris Setosa Iris Versicolor Iris Virginica Sepal.Width Sepal.Width Sepal.Width Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Width Petal.Width Petal.Width Sepal.Width Sepal.Width Sepal.Width Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Length Sepal.Length Petal.Width Petal.Width Petal.Width All three species. Comments?

  35. Radial Axes Data explorations using stars(...) again stars (data[ran.order,], lwd=1.25, labels=NULL, radius=FALSE, col.lines = rep ("steelblue", n), nrow=10, ncol = 15, key.loc= c (12, - 0.5), main="Iris data")

  36. Radial Axes Iris data Sepal.Width Petal.Length Sepal.Length Petal.Width

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend