[R] kiteChart to show real values with scalebar
bodiless
nlamp at hcmr.gr
Fri Apr 27 20:12:18 CEST 2012
Dear R-users
I hope someone could help me on this problem.
I want to create a multiple kiteChart showing the real values with a
scalebar on each indicating the scale .
Here are some sample data to show what I want to achieve.
Y <- read.table(textConnection("Sample1 Sample2
60 20
150 50
300 100"),header=TRUE)
X <- read.table(textConnection("Sample1 Sample2
6 2
15 5
30 10"),header=TRUE)
par(las=1,mfrow=c(2,1))
kiteChart(t(Y),xlim=c(-400,400),timelabels=c("2-3cm","1-2cm","0-1cm"),
normalize=FALSE,shownorm=FALSE,timex=FALSE)
kiteChart(t(X),xlim=c(-400,400),timelabels=c("2-3cm","1-2cm","0-1cm"),
normalize=FALSE,shownorm=FALSE,timex=FALSE)
My first problem with the above approach is that the kites in both graphs
are overlapping. If I take out the xlim switch then the kites are too large
and you can't see anything. If I use the xlim switch then they are not
plotted next to each other as they should. Please note that I could use
normalize=TRUE and then they are plotted ok but I don't want to normalize
them.
My second problem is that I have data which are way too smaller that the
values shown in data.frame X. So, if the first graph has large values and
the second very small values then on the second graph you see only a thin
line. Therefore I want to multiply the small values of data.frame X by a
factor to make the kites visible but then I need to place a scalebar on each
graph showing e.g. that for the 0-1cm the top graph is 0-300 and the lower
graph is 0-30.
Hope that my post is not very confusing.
Thanks in advance.
--
View this message in context: http://r.789695.n4.nabble.com/kiteChart-to-show-real-values-with-scalebar-tp4593386p4593386.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list