Skip to content

More efficient use of reshape?

5 messages · David Winsemius, Nathan Miller, John Kane

#
On Dec 13, 2012, at 9:16 AM, Nathan Miller wrote:

            
You do realize that the 'reshape' function is _not_ in the reshape  
package, right? And also that the reshape package has been superseded  
by the reshape2 package?
#
I think David was pointing out that reshape() is not a reshape2 function.  It is in the stats package.

I am not sure exactly what you are doing but perhaps something along the lines of 

library(reshape2)      
mm  <-  melt(clim.data, id = Cs("yr_frac", "yr_mn",    "AMO", "NINO34", "SSTA"))

is a start?  

I also don't think that the more recent versions of ggplot2 automatically load reshape2 so it may be that you are working with a relatively old installation of ggplot and reshape?

sessionInfo()
R version 2.15.2 (2012-10-26)
Platform: i686-pc-linux-gnu (32-bit)

locale:
 [1] LC_CTYPE=en_CA.UTF-8       LC_NUMERIC=C               LC_TIME=en_CA.UTF-8       
 [4] LC_COLLATE=en_CA.UTF-8     LC_MONETARY=en_CA.UTF-8    LC_MESSAGES=en_CA.UTF-8   
 [7] LC_PAPER=C                 LC_NAME=C                  LC_ADDRESS=C              
[10] LC_TELEPHONE=C             LC_MEASUREMENT=en_CA.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] grid      stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] lubridate_1.2.0    directlabels_2.9   RColorBrewer_1.0-5 gridExtra_0.9.1    stringr_0.6.2     
[6] scales_0.2.3       plyr_1.8           reshape2_1.2.1     ggplot2_0.9.3     

loaded via a namespace (and not attached):
[1] colorspace_1.2-0 dichromat_1.2-4  digest_0.6.0     gtable_0.1.2     labeling_0.1    
[6] MASS_7.3-22      munsell_0.4      proto_0.3-9.2    tools_2.15.2    






John Kane
Kingston ON Canada
____________________________________________________________
Receive Notifications of Incoming Messages
Easily monitor multiple email accounts & access them with a click.
Visit http://www.inbox.com/notifier and check it out!