[R] 3D plotting in R

ucgamdo@ucl.ac.uk ucgamdo at ucl.ac.uk
Fri Sep 19 14:57:28 CEST 2003


For plotting 3D points, you might want to check the function 'cloud' in the
'lattice' package (some good examples in the help file), you can feed the 3
most important factors to the function and see a 3d rep of your data. A
perhaps, a better 3D representation comes from the function 'sm.density' in
the 'sm' package, follow the examples for the 3d case in help(sm.density).
If the data aggregates itself visually in obvious clusters, you can use the
functions 'pam' (for small datasets) or 'clara' (for larger ones) in the
package 'cluster' to identify which elements belong to each cluster. In
this case you should first determine visually, how many cluster are
present, and them, feed this value into these functions, say 

clara('data', k = 4)

where 'data' would, for example, be a 3 columns matrix representing some
sort of Principal Component Analysis, etc. and 4 is the number of groups
you suspect are present in your data.

Alternatevely, you can try independent component analysis on your data. I
think is more powerful analysis that goes beyond the classic principal
components stuff. Check package 'fastICA' in CRAN for details.

Hope this is useful.




More information about the R-help mailing list