Re: [R] Cairo SVG backend

2007-10-27 Thread Prof Brian Ripley
You need recent enough cairo libraries in your OS. Your OS appears to date from mid 2006, so likely you need a later cairo: my system is using cairo 1.4.10 and found all the backends. Your kernel is quite old: does your OS have kernel and cairo updates you have not applied? On Fri, 26 Oct

[R] calculating correlation of a Supply/Demand measure and price change (in high frequency time series data)

2007-10-27 Thread Kenneth Spriggs
Regarding financial data: I have a high frequency (1 minute) measure of supply/demand and I'd like to know if it has any influence on short term price changes (also 1 minute). Question: How do I calculate the correlation between this supply/demand measure and price changes (correctly)? Some

[R] [non-statistics question]methodological problem

2007-10-27 Thread eugen pircalabelu
Good afternoon! As mentioned in the subject, my question regards more the methodological part that accompanies survey design and the statistical part that is involved. So, I have the following data: a-data.frame (id_hh=c(1:5), strata=c(1,1,2,2,1), Nhstrata=c(100,100,200,200,100),

[R] Oracle and RJDBC

2007-10-27 Thread Slawek Smyl
Hello, I am using Oracle 10.2 and R 2.6 on Windows XP. I found RODBC working generally OK (with some minor problems) but very slow, so I am trying to use RJDBC. While getting things (dbGetQuery) works fine, I have problems with saving: dbWriteTable(conn, WAV, save_df, overwrite = F, append = T,

Re: [R] R routines vs. MATLAB/SPSS Routines

2007-10-27 Thread Patrick Burns
Many of these points are discussed in http://www.burns-stat.com/pages/Tutor/R_relative_statpack.pdf a collaborative effort that I edited. In particular the final quote by Jonathan Baron addresses point 5: Another point, which I repeatedly make to students, is that R is free and will continue to

Re: [R] Newton method iteration problem

2007-10-27 Thread kevinchang
Thanks Chales for pointing out the errors. I fixed an errorr and R accepted my rootFinding code. But the problem right now is that my code will work only if the intialX value is close enough to the solution. Otherwise, R says there is missing true/false value in the codition test of while loop.

[R] [non-R question] methodological problem

2007-10-27 Thread eugen pircalabelu
Sorry, I meant non-R question. Sorry for the inconvenience! __ [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE

[R] Bandwidth selection for kernel regression.

2007-10-27 Thread Andreas Klein
Hello everyone. I have got a little question on selecting a proper bandwidth for kernel regression. As you all know, for bandwidth selection in a regression case you can use the averaged squared error as a criterion for goodness of fit, but for some problems (e.g. the bandwidth h approaches to

[R] having problems re-ordering a dataframe

2007-10-27 Thread Chabot Denis
Dear R users, I need to reorder a dataframe using 3 variables for the determine the sorting order. When I create a simple dataframe to test the method, things work as I expected: a1 - rep(1:10, each=8) a2 - rep(rep(1:2, each=4), 10) a3 - rep(c(1:4),20) (a - data.frame(a1, a2, a3)) for each

[R] Comparing lagged time series

2007-10-27 Thread j taecha
As a newbie to R I have the following question. I would like to compare values in a time series with values of the same series x observations ago. In gretl this is simply done like so: In R, I seem not to get it working. I have tried lag(data,-x) to obtain the lagged time series which

Re: [R] Newton method iteration problem

2007-10-27 Thread Charles C. Berry
On Sat, 27 Oct 2007, kevinchang wrote: Thanks Chales for pointing out the errors. I fixed an errorr and R accepted my rootFinding code. But the problem right now is that my code will work only if the intialX value is close enough to the solution. Otherwise, R says there is missing

Re: [R] having problems re-ordering a dataframe

2007-10-27 Thread Duncan Murdoch
Chabot Denis wrote: Dear R users, I need to reorder a dataframe using 3 variables for the determine the sorting order. When I create a simple dataframe to test the method, things work as I expected: a1 - rep(1:10, each=8) a2 - rep(rep(1:2, each=4), 10) a3 - rep(c(1:4),20) (a -

[R] creating large graphs

2007-10-27 Thread Jesse D Lecy
Dear useRs, I have a large dataset (600 to 2000 observations) that I need to cluster with a hierarchical technique, and then examine so that I can use cutree to extract various groups. I would like to visualize the results of hclust in a dendrogram, but this is obviously too much data for

Re: [R] having problems re-ordering a dataframe

2007-10-27 Thread Chabot Denis
Thank you very much for your detailed explanation and two solutions, Duncan. Denis Le 07-10-27 à 12:44, Duncan Murdoch a écrit : Chabot Denis wrote: Dear R users, I need to reorder a dataframe using 3 variables for the determine the sorting order. When I create a simple dataframe to

Re: [R] How to make own function load automatically on startup

2007-10-27 Thread Katharine Mullen
Regarding your first issue: you could make a package to contain your function (see ?package.skeleton and the manual Writing R extensions) - then you could use library(yourpackagename). Or you could save the definition of your function(s) in a text file, and use source(textfilename) to load the

[R] Selectively swapping labels between factors

2007-10-27 Thread Michael Kubovy
Dear R-helpers, I'm trying to selectively swap labels between two factors, depending on an indicator variable i. Can you point me to a solution, and perhaps how I could have found it? labels(fact1) is a character vector of r row numbers levels(fact1) is a character vector of the n r unique

Re: [R] How to make own function load automatically on startup

2007-10-27 Thread Gabor Csardi
Jonas, if you want the function to load really automatically, without running source of anything, read ?Startup Basically you need to create an .Rprofile file (its location depends on your operating system) containing the R code you want to run at startup. Gabor On Sat, Oct 27, 2007 at

Re: [R] Selectively swapping labels between factors

2007-10-27 Thread Charles C. Berry
On Sat, 27 Oct 2007, Michael Kubovy wrote: Dear R-helpers, I'm trying to selectively swap labels between two factors, depending on an indicator variable i. Can you point me to a solution, and perhaps how I could have found it? labels(fact1) is a character vector of r row numbers

[R] How to generate all permutation of 0-1 sequences in R?

2007-10-27 Thread roger chan
Hi, folks: I need to generate all 0-1 sequences with given length,say,n=3, the ideal result would be the following matrix: 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1 Any help would be appreciated. -- View this message in context:

Re: [R] How to generate all permutation of 0-1 sequences in R?

2007-10-27 Thread roger chan
Thanks a lot. Henrique Dallazuanna wrote: Hi, expand.grid(x=c(0,1), y=c(0,1), z=c(0,1)) -- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40 S 49° 16' 22 O On 27/10/2007, roger chan [EMAIL PROTECTED] wrote: Hi, folks: I need to generate all 0-1 sequences with given

Re: [R] Meta-analysis mixed model

2007-10-27 Thread Gregor Gorjanc
Diane Srivastava srivast at zoology.ubc.ca writes: I have a meta-analysis dataset which I would like to analyze as a mixed model, where the y-variable is a measure of effect size, the random effect is the study from which the effect size was extracted, and the fixed effect is a categorical

[R] Package Installer Fails in OSX 10.5 Leopard

2007-10-27 Thread Don Kalar
Hello all, I apologize in advance if this is not the correct list to post these sorts of issues. When attempting to install the latest stable build of R (2.6) or the most recent nightly build from R.research.att.com, the installer disables the ability to actually install R or any of the other

Re: [R] Package Installer Fails in OSX 10.5 Leopard

2007-10-27 Thread Mark Wardle
least=list. it is late (here)! On 28/10/2007, Mark Wardle [EMAIL PROTECTED] wrote: Hi. Sorry to hear you are having problems. I'm not installing Leopard just yet, as I cannot live without a working system running R, PostgreSQL, Filemaker, and Adobe applications. At least two on that least

Re: [R] Package Installer Fails in OSX 10.5 Leopard

2007-10-27 Thread Mark Wardle
Hi. Sorry to hear you are having problems. I'm not installing Leopard just yet, as I cannot live without a working system running R, PostgreSQL, Filemaker, and Adobe applications. At least two on that least are said to have problems with Leopard! If no-one else replies, try the Mac R help list.