[R-SIG-Finance] plotting market cap heatmap
Khanh Nguyen
knguyen at cs.umb.edu
Mon Nov 2 17:41:52 CET 2009
Hi,
Let say I have this data frame.
> tickers <- toupper(letters[1:5])
> market.cap <- c(100, 60, 700, 1500, 450)
> change <- c(0.02, 0.004, 0.0012, 0.001, 0.030
> data <- data.frame(tickers, market.cap, change)
> data
tickers market.cap change
1 A 100 0.0200
2 B 60 0.0040
3 C 700 0.0012
4 D 1500 0.0010
5 E 450 0.0300
and I'd like to plot a heatmap whose market cap is proportional to the
size of the cell, similar to http://finviz.com/map.ashx. Could
somebody please give me a pointer? Thanks.
-k
More information about the R-SIG-Finance
mailing list