Re: [R] summarizing a complex dataframe

2012-01-11 Thread Bert Gunter
Well, if I understand what you want to do, it's straightforward, ?[ (pay attention to the use of column names) and ?grep would pick out the columns you want and you could then use mapply or maybe rowMeans or whatever to get your summaries. HOWEVER ... I think what you should really should do is

[R] Checking dates for entry errors

2012-01-11 Thread Paul Miller
Hello Everyone,   I have a question about how best to check dates for entry errors. I recently discovered that R will read the incorrectly entered date 11/23/21931 without producing a warning or an error message at least under some circumstances.   as.Date(11/23/21931, format = %m/%d/%Y) [1]

Re: [R] Storing/Restoring R objects

2012-01-11 Thread Rich Shepard
On Wed, 11 Jan 2012, David Winsemius wrote: Then R will not find it. (Actually there will be no .RData file until R executes save.image() at the end of the session. R does not create a fresh .RData at the beginning of a session.) David, That's good to know. Could I then specify which

Re: [R] summarizing a complex dataframe

2012-01-11 Thread David Winsemius
On Jan 11, 2012, at 3:55 PM, Christopher G Oakley wrote: I need some help summarizing complex data frames (small example below): m1_1 m2_1 m3_1 m1_2 m2_2 m3_2 i1111222 i1211222 i2221222 For an arbitrary number of

Re: [R] rjava on FreeBSD

2012-01-11 Thread Rainer Hurling
On 11.01.2012 22:51 (UTC+1), Hasan Diwan wrote: Trying to install Rjava on FreeBSD 9 and am getting the following error: install.packages('rJava') trying URL 'http://cran.cnr.Berkeley.edu/src/contrib/rJava_0.9-3.tar.gz' Content type 'application/x-gzip' length 537153 bytes (524 Kb) opened URL

Re: [R] Restricting R session

2012-01-11 Thread Thomas Lumley
2012/1/12 Uwe Ligges lig...@statistik.tu-dortmund.de: On 10.01.2012 20:30, Antonio Rodriges wrote: Hello, Is it possible to use R on public server where each user has its own restricted R session? This entirely depends on the definition of restricted, otherwise the answer is yes. More

Re: [R] Storing/Restoring R objects

2012-01-11 Thread David Winsemius
On Jan 11, 2012, at 5:16 PM, Rich Shepard wrote: On Wed, 11 Jan 2012, David Winsemius wrote: Then R will not find it. (Actually there will be no .RData file until R executes save.image() at the end of the session. R does not create a fresh .RData at the beginning of a session.) David,

Re: [R] 2D filter in R?

2012-01-11 Thread Rolf Turner
On 12/01/12 09:17, Michael wrote: Hi all, I am looking for a command for doing 2D filtering (rectangular or Gaussian) in R... I have looked at ksmooth, filter and convolve but they seem to be 1D... Any thoughts? Thanks a lot! I'm not sure what you really need/want to do, but you might have

Re: [R] 2D filter in R?

2012-01-11 Thread Bert Gunter
?loess ## in base R does 2d filtering , though it's not a Gaussian one -- Bert On Wed, Jan 11, 2012 at 3:00 PM, Rolf Turner rolf.tur...@xtra.co.nz wrote: On 12/01/12 09:17, Michael wrote: Hi all, I am looking for a command for doing 2D filtering (rectangular or Gaussian) in R... I have

Re: [R] 2D filter in R?

2012-01-11 Thread Michael
Okay thanks guys! I was actually looking for image processing libraries in R. Specifically, I am looking for something like filter2d for images(pixels)... (speed is not a concern for me, since my images are really small, 200x200, etc.) And in fact, these are not images, these are 2d matrix

Re: [R] 2D filter in R?

2012-01-11 Thread Bert Gunter
The Bioconductor list/repository will have lots of image processing stuff. -- Bert On Wed, Jan 11, 2012 at 3:21 PM, Michael comtech@gmail.com wrote: Okay thanks guys! I was actually looking for image processing libraries in R. Specifically, I am looking for something like filter2d for

Re: [R] 2D filter in R?

2012-01-11 Thread Michael
I looked the loess up... But I am confused... what should be my formula if I just want to smooth the numbers of my matrix x? And those lots of parameters are daunting... what are the essential ones that I should definitely set up? I remember for 2d Gaussian filter, I just need to set one

Re: [R] 2D filter in R?

2012-01-11 Thread Michael
Thanks a lot Bert! Are z, y and x are of the same length? And after the loess I just reshape the stacked outputs back into a 2d matrix? Thanks again! On Wed, Jan 11, 2012 at 5:33 PM, Bert Gunter gunter.ber...@gene.com wrote: You have to set the data up as 3 columns: z = Values y = row

Re: [R] Vegan(ordistep) error: Error in if (aod[1, 5] = Pin) { : missing value where TRUE/FALSE needed

2012-01-11 Thread Nevil Amos
Whilst the constrained proportion was 0 in the example below I am getting the error in cases where this is not so. See new output pasted below [1] ORDISTEP RDA1 BOTH WAYS [1] [1] SFW ALL Adult [1]

[R] R error in make check

2012-01-11 Thread Anirban Jana
Hi, After building R 2.14.1 on a Linux system (SUSE Linux Enterprise Server 11 (x86_64) ), I ran make check but it halted with the foll error: Testing examples for package âbaseâ Error: testing 'base' failed Execution halted I looked in build dir/test/Examples/base-Ex.Rout.fail and found the

[R] Error in charToDate(x)

2012-01-11 Thread Monchichi
Dear all, I have a problem while working with hourly data of fx rates. I've read from a csv file, the following way: csv-file like: Date,Open,High,Low,Close,Volume 2011-08-11 03:00:00,1.41758,1.42205,1.41625,1.42174,8974 ... 2011-08-12 04:00:00,1.42175,1.42413,1.42067,1.42172,7229 ... 2011-12-30

Re: [R] plotOHLC(alpha3): Error in plotOHLC(alpha3) : x is not a open/high/low/close time series

2012-01-11 Thread Ted Byers
Thanks Joshua, That did it. Cheers, Ted -- View this message in context: http://r.789695.n4.nabble.com/plotOHLC-alpha3-Error-in-plotOHLC-alpha3-x-is-not-a-open-high-low-close-time-series-tp4283217p4286963.html Sent from the R help mailing list archive at Nabble.com.

Re: [R] 2D filter in R?

2012-01-11 Thread David Winsemius
On Jan 11, 2012, at 6:21 PM, Michael wrote: Okay thanks guys! I was actually looking for image processing libraries in R. Specifically, I am looking for something like filter2d for images(pixels)... (speed is not a concern for me, since my images are really small, 200x200, etc.) And in

[R] multcomp two-way anova with interactions within and between

2012-01-11 Thread Schreiber, Stefan
Hi all, I'd like to compare all levels of my interaction with each other. I read the pdf 'Additional multcomp Examples' but even though there is an example with an interaction it doesn't work for me when I want to compare within and between groups. Here is an example:

[R] cannot get tweets from twitteR

2012-01-11 Thread Sachinthaka Abeywardana
Hi all, I was following the tutorial in: http://www.rdatamining.com/examples/text-mining and using the package twitteR i attempted to execute userTimeline and got the error: rdmTweets-userTimeline(rdatamining,n=100)Error in .self$twFromJSON(out) : Error: Rate limit exceeded. Clients may not

Re: [R] summarizing a complex dataframe

2012-01-11 Thread jim holtman
will this do it for you: x - read.table(text =m1_1 m2_1 m3_1 m1_2 m2_2 m3_2 +111222 + 211222 + 221222, header = TRUE) # split out the main names of the column x.names - do.call(rbind, strsplit(names(x), _)) x.names

Re: [R] RGL- Drawing Circle

2012-01-11 Thread Duncan Murdoch
On 12-01-11 9:08 AM, gli wrote: thanks Duncan. I think want my circle to be in user coordinates. I tried the first code u gave me and it gives me a circle. but how can i: 1) change the radius ? 2) place the circle at a given x,y,z coordinate? 3) turn it 90 degree up like these circle plate

[R] Points inside a polygon

2012-01-11 Thread Hasan Diwan
I have a list of bounds for a series of polygons. I do understand the formula to determine whether point i is within polygon X (X[x1] i[x] X[x2] i[x] X[y1] i[y] X[y2] i[y]), and I can apply this throughout the dataset. However, this naive algorithm doesn't scale very well. The data set

[R] summing NAs in aggregate

2012-01-11 Thread Spitzer, Matthew
Hello, I would like to please ask for assistance with aggregate sum. I have a data set with consisting of two grouping variables (id, visit) and several other variables. I would like to sum the variables for each id and visit, but am having problems with na.rm. na.rm=TRUE seems to replace

Re: [R] cannot get tweets from twitteR

2012-01-11 Thread Sachinthaka Abeywardana
Btw I tried this on the terminal in R and it worked, restarted Rstudio and it still doesn't work there. Rstudio bug or something else? Sachin [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] summing NAs in aggregate

2012-01-11 Thread R. Michael Weylandt
Perhaps this would work: spitzSum - function(x) if(all(is.na(x))) NA else sum(x, na.rm = TRUE) Michael On Wed, Jan 11, 2012 at 11:18 PM, Spitzer, Matthew matthew.spit...@bmc.org wrote: Hello, I would like to please ask for assistance with aggregate sum.  I have a data set with consisting of

Re: [R] R error in make check

2012-01-11 Thread Prof Brian Ripley
You should ask this on R-devel, and tell them exactly what compilers you used. See the posting guide: this falls under 'Questions likely to prompt discussion unintelligible to non-programmers should go to to R-devel.' But yes, it is something to worry about and it looks as if your compiler

[R] kruskal wallis post hoc?

2012-01-11 Thread Iasonas Lamprianou
Dear all, I run a kruskal wallis test and found significant results. Then, I conducted all pairwise comparisons and found no significant results. Could anyone please give me a hint as to why this happens or redirect me towards a specific web page where I can find more info? (I used alpha=5%

<    1   2