Hello Ellen, First up I think you can use reshape to get your data into a form that kiteChart will work with...
# assuming your matrix or data.frame is called X Xwide <- reshape(X, timevar="depth", idvar="distance", direction="wide") # replace NAs with 0 (don't think kiteChart likes NA) Xwide[ is.na(Xwide) ] <- 0 kiteChart(Xwide) I haven't considered all of your plot requirements here but hopefully this will get you started. Michael On 13 October 2010 19:11, elpape <ellen.p...@gmail.com> wrote: > > Dear everyone, > > I would like to create a kite chart in which I plot densities (width of the > vertical kites) in relation to sediment depth (on reversed y-axis) for 6 > different locations (Distances from seep site, on x-axis on top of the > plot). The dataset I would like to use is: > > > Distance_from_seep_site Sedimentdepth Density > 1100 0 107.8 > 1100 1 264.6 > 1100 2 284.2 > 1100 3 470.4 > 1100 4 58.8 > 100 0 98 > 100 1 176.4 > 100 2 499.8 > 100 3 548.8 > 100 4 401.8 > 100 5 107.8 > 10 0 51.3 > 10 1 22.8 > 10 2 79.8 > 10 3 68.4 > 10 4 17.1 > 10 5 5.7 > 10 6 17.1 > 5 0 188.1 > 5 1 267.9 > 5 2 376.2 > 5 3 233.7 > 5 4 165.3 > 5 8 5.7 > 5 9 5.7 > 2 0 74.1 > 2 1 102.6 > 2 2 85.5 > 2 3 91.2 > 2 4 34.2 > 2 5 5.7 > 2 6 11.4 > 2 8 11.4 > 2 10 28.5 > 2 11 22.8 > 0 0 461.7 > 0 1 273.6 > 0 2 79.8 > 0 3 68.4 > 0 4 34.2 > 0 5 22.8 > 0 6 51.3 > 0 8 68.4 > 0 9 39.9 > 0 11 22.8 > > I have tried to rearrange the data, but I do not seem to get the output that > I desire... > > Can anyone help me? > > Thank you so much! > Ellen > > > > -- > View this message in context: > http://r.789695.n4.nabble.com/vertical-kites-in-KiteChart-plotrix-tp2993295p2993295.html > Sent from the R help mailing list archive at Nabble.com. > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.