Hi-
Tabular data have been provided to me within .csv files. I need to transform
the data from tabular format into a dataframe with three
columns. The columns need to be the table row id, table column id, and the
tabulated variable. An example dataset can be downloaded here:

https://docs.google.com/leaf?id=0B0d3zfSSPFQsOGFkYThhYTYtOTE2Zi00NTNkLThmMzYtNDEyMTY5MjRiN2Qy&sort=name&layout=list&num=50

So I need that to be like:

Season   Area Variable
2009-10   38    5
2008-09   38    NA
...etc
2009-10   39    1
2008-09   39    3
...etc

>From there I need to show 'Variable' as a series of bubbles scaled to
summary categories of 'Variable'.
If x is my object storing the data frame above, something like:

x$var.cat[x$Variable %in% 1:5] <- 1
x$var.cat[x$Variable %in% 6:10] <- 2

plot(x=x$Area, y=x$Season, type='n')
points(x=x$Area, y=x$Season, pch=1, cex=x$var.categ)

Transforming tabular data has turned out to be trickier than I expected and
I would appreciate advice. Although my bubble plot
scheme should work, it would be nice to hear of better ways on that too...

Thanks,
Tim

        [[alternative HTML version deleted]]

______________________________________________
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.

Reply via email to