[R] install local package

2009-06-10 Thread Jorge Cornejo
Hi, I'm working on a package that I would someday put in CRAN. Now I want to test it on my computer. I already check and compile the files but I don't know how to install the package located on my hard drive. I'm running R under linux. Can anyone tell my how to do it? Thanks in advance. _

Re: [R] How to order an data.table by values of an column?

2009-06-10 Thread Allan Engelhardt
See help("order") and help("[.data.frame"). df <- data.frame(Categ=c(468,351,0,234,117),Perc=c(31.52,27.52,0.77,22.55,15.99)) df[order(df$Categ),] # Categ Perc # 3 0 0.77 # 5 117 15.99 # 4 234 22.55 # 2 351 27.52 # 1 468 31.52 Lesandro wrote: Hello! Can you help me? How to

Re: [R] Install local package

2009-06-10 Thread Ronggui Huang
## Check the package > R CMD check path.of.package ## Build the package > R CMD build pathof.package ## INSTALL the package > R CMD INSTALL path.of.package You can use _R --help _ (from within terminal) to get more information. Ronggui 2009/6/11 Jorge Cornejo : > Hi, I'm working on a package th

[R] Integrate function in R

2009-06-10 Thread Bhargab Chattopadhyay
Hi! Can anyone please let me know what numerical integration procedure does the integrate function in package stats follow? Thank you in advance Shant [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://

[R] How to order an data.table by values of an column?

2009-06-10 Thread Lesandro
Hello! Can you help me? How to order an data.table by values of an column? Per example: Table no initial Categ Perc 468  31.52 351  27.52 0  0.77 234  22.55 117  15.99 table final Categ Perc 0  0.77 117  15.99 234  22.55 351  27.52 468  31.52 Lesandro Veja quais são os assuntos do m

[R] Install local package

2009-06-10 Thread Jorge Cornejo
Hi, I'm working on a package that I would someday put in CRAN. Now I want to test it on my computer. I already check and compile the files but I don't know how to install the package located on my hard drive. I'm running R under linux. Can anyone tell my how to do it? Thanks in advance. _

[R] Problem with tabbed notebook (tcltk, Iwidgets)

2009-06-10 Thread Talita Perciano
Hi, I'm using R version 2.9.0 and I'm trying to execute an example using tabnotebook from iwidgets. Unfortunately I get a problem as you can see bellow: > library(tcltk) Loading Tcl/Tk interface ... done > library(tkrplot) > tclRequire("Iwidgets") 4.0.1 > > tt <- tktoplevel() > tkpack(tn <- t

Re: [R] Vista + R = *!!?@

2009-06-10 Thread Ronggui Huang
lmer will not produce p-value but glmer does. So, if you want to estimate a lmm model, you can use lme in nlme package instead. Ronggui 2009/6/11 John Townsend-Mehler : > Hello People of R, > > Is there any way that I can get R to function properly using Vista.  I get > very strange output using

Re: [R] Vista + R = *!!?@

2009-06-10 Thread milton ruser
Hi there, I have run R on vista using glm(), mle, mle2 (bbmle), spatstats without problem. cheers milton On Wed, Jun 10, 2009 at 5:33 PM, Marc Schwartz wrote: > > On Jun 10, 2009, at 1:57 PM, John Townsend-Mehler wrote: > > Hello People of R, >> >> Is there any way that I can get R to function

Re: [R] R: Best way to plot a Matrix of all possible pair combinations

2009-06-10 Thread jim holtman
try 'levelplot' in the lattice package. On Wed, Jun 10, 2009 at 10:05 AM, suparna mitra < suparna.mi...@googlemail.com> wrote: > Hallo R Users, > Please help > I have some distance matrix data like > > M[1:10,] > [,1] [,2] [,3] [,4] [,5] [,6] > [1,] 0.875

[R] Austria, September, 2009: Statistical Learning and Data Mining Course

2009-06-10 Thread Trevor Hastie
Short course: Statistical Learning and Data Mining III: Ten Hot Ideas for Learning from Data Trevor Hastie and Robert Tibshirani, Stanford University Danube University Krems, Austria 25-26 September 2009 This two-day course gives a detailed overview of statistical models for data mining, infer

Re: [R] problem with PCA loading plot

2009-06-10 Thread David Winsemius
On Jun 10, 2009, at 1:26 PM, Fireblast wrote: Hi, I am a beginner with R. I would like to get a loading plot of PC 3 vs PC 1. For PC 1 vs PC 2 I use library(pls) loadingplot(pca.result, comps = 1:2, scatter = TRUE, labels="names") if I try loadingplot(pca.result, comps = 1:3, scatter =

[R] Mixed model specification

2009-06-10 Thread Boks, M.P.M.
Dear R-friends, I would very much appreciate any direction you can give me regarding the following: I am trying to specify a model with three random effects (var1, var2 and constant) in two levels (nested in pair): lme(dependend ~ age + gender, random=list(pair = pdIdent(~var1 + var2 +1))

[R] Help on drawing stars and radars in R

2009-06-10 Thread Caroline Gideon-Adeniyi
Hi I don't know if you can help. I am a 2nd year Bsc Cosmetic Science student and in R I need some help in drawing stars. The problem that I have is I want to recreate a radar diagram similar to the one in excel. I have put in these commands in a script window: stars(shampoo1[, 1:6], locatio

Re: [R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread David Winsemius
On Jun 10, 2009, at 1:36 PM, Logickle wrote: Sorry, there may be some lingo for describing the extraction problem I have, but I don't know it. I have a matrix of 2 rows and N columns, and a vector of N 1s and 2s. Matrix M: 1 2 3 4 ... N 1A C D G ...

Re: [R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 7:05 PM, William Dunlap wrote: Subscripting by a 2-column matrix M[cbind(v, seq_len(ncol(M)))] uses much less space (hence time) than making the ncol(M) by ncol(M) intermediate matrix just to extract its diagonal. E.g. test <- function(n, seed) { if (!missing(seed))

Re: [R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread William Dunlap
Subscripting by a 2-column matrix M[cbind(v, seq_len(ncol(M)))] uses much less space (hence time) than making the ncol(M) by ncol(M) intermediate matrix just to extract its diagonal. E.g. test <- function(n, seed) { if (!missing(seed)) set.seed(seed) M <- matrix(sample(LETTERS, 2*

[R] smooth.spline() fucntion

2009-06-10 Thread array chip
Hi, all, I found that the smooth.spline() function produces different results between R and S-Plus. I was trying to play different parameters of the function without any success. The script of the function contains Fortran code, so it seems impossible to port the code from S-Plus to R (or I may

Re: [R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 6:26 PM, Marc Schwartz wrote: On Jun 10, 2009, at 12:36 PM, Logickle wrote: Sorry, there may be some lingo for describing the extraction problem I have, but I don't know it. I have a matrix of 2 rows and N columns, and a vector of N 1s and 2s. Matrix M: 1 2

Re: [R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 12:36 PM, Logickle wrote: Sorry, there may be some lingo for describing the extraction problem I have, but I don't know it. I have a matrix of 2 rows and N columns, and a vector of N 1s and 2s. Matrix M: 1 2 3 4 ... N 1A C D G ..

Re: [R] Preventing .Call from printing a blank line to the R console on Windows

2009-06-10 Thread Duncan Murdoch
On 10/06/2009 5:16 PM, Joel wrote: Hello everyone, I am using the CVODES integrator in the Rsundials package. Every time I call the integrator, a blank line is printed in the console. Using debug, I was able to isolate the problem to this line in the function cvodes(...): solutions = .Call("c

Re: [R] gpc.poly datatype

2009-06-10 Thread Duncan Murdoch
On 10/06/2009 1:53 PM, Derek Lacoursiere wrote: I have a list of polygons generated by the contourLines() command (each object of the list is a list in itself with two objects: a vector of x values, and a vector of y values for each vertex). I wish to convert that list into a gpc.poly object of

[R] Comparing R and SAs

2009-06-10 Thread jude.ryan
Satish, For a comparison of SAS and S, see the document "An Introduction to S and the Hmisc and Design Libraries" by Carlos Alzola and Frank E. Harrell. Frank Harrell is an expert in both SAS and R. You can download this document from http://www.r-project.org/, then click on manuals, and then c

[R] Performance Data Analysis Class using R

2009-06-10 Thread Red Roo
GUERRILLA DATA ANALYSIS TECHNIQUES (GDAT) with an emphasis on R and PDQ-R modeling tools A

Re: [R] Difficulties with the simpest table

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 11:27 AM, Dmitry Gospodaryov wrote: I have the data arranged in table (in Excel, or Notepad): x y 0 100 2 100 4 80 6 40 8 0 I need to transfer these data in R file and then going to operate

[R] Preventing .Call from printing a blank line to the R console on Windows

2009-06-10 Thread Joel
Hello everyone, I am using the CVODES integrator in the Rsundials package. Every time I call the integrator, a blank line is printed in the console. Using debug, I was able to isolate the problem to this line in the function cvodes(...): solutions = .Call("cvodes", PACKAGE = "Rsundials", as.dou

Re: [R] Difficulties with the simpest table

2009-06-10 Thread Liviu Andronic
Hello Dmitry, On 6/10/09, Dmitry Gospodaryov wrote: > I have the data arranged in table (in Excel, or Notepad): > > x y > > 0 100 > 2 100 > 4 80 > 6 40 > 8 0 > > I need to transfer these data in R file and then g

Re: [R] Vista + R = *!!?@

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 1:57 PM, John Townsend-Mehler wrote: Hello People of R, Is there any way that I can get R to function properly using Vista. I get very strange output using lmer, as in no p-values. Is there ANY way I can fix this. That's not a Vista issue, it is a statistical theo

[R] Vista + R = *!!?@

2009-06-10 Thread John Townsend-Mehler
Hello People of R, Is there any way that I can get R to function properly using Vista. I get very strange output using lmer, as in no p-values. Is there ANY way I can fix this. Thank you for your time, John Townsend-Mehler PhD Candidate Department of Zoology Michigan State University

[R] problem with PCA loading plot

2009-06-10 Thread Fireblast
Hi, I am a beginner with R. I would like to get a loading plot of PC 3 vs PC 1. For PC 1 vs PC 2 I use library(pls) loadingplot(pca.result, comps = 1:2, scatter = TRUE, labels="names") if I try loadingplot(pca.result, comps = 1:3, scatter = TRUE, labels="names") I get the loading plots of

[R] How to extract from a matrix based on indices in a vector?

2009-06-10 Thread Logickle
Sorry, there may be some lingo for describing the extraction problem I have, but I don't know it. I have a matrix of 2 rows and N columns, and a vector of N 1s and 2s. Matrix M: 1 2 3 4 ... N 1A C D G ... 2B D F H ... Vector v:

[R] Difficulties with the simpest table

2009-06-10 Thread Dmitry Gospodaryov
I have the data arranged in table (in Excel, or Notepad): x y 0 100 2 100 4 80 6 40 8 0 I need to transfer these data in R file and then going to operate with x and y as with variables. I should note, that I hav

[R] nonparametric test for row of a matrix

2009-06-10 Thread Stefo Ratino
Hi, Are there any nonparametric test for ordinal categorical data for row of a matrix?   Thank you very much, Stefo [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help

Re: [R] Predict GARCH

2009-06-10 Thread Liviu Andronic
Hello, On 6/10/09, Daniel Mail wrote: > i was trying to predict values for a garch, so i did: > > predict(fitgarch,n.ahead = 20) > > but this doesn't work. Someone can tell me how to get the 20 values ahead of > a garch model. > You didn't specify what function you used to obtain the GARCH mo

[R] gpc.poly datatype

2009-06-10 Thread Derek Lacoursiere
I have a list of polygons generated by the contourLines() command (each object of the list is a list in itself with two objects: a vector of x values, and a vector of y values for each vertex). I wish to convert that list into a gpc.poly object of multiple contours. How do I do this? gpclib app

Re: [R] GeoXp package

2009-06-10 Thread Zeljko Vrba
On Wed, Jun 10, 2009 at 08:21:06AM +0200, Poizot Emmanuel wrote: > Error in fun(...) : >GDAL Error 1: libgrass_I.so: Ne peut ouvrir le fichier d'objet > partagé: Aucun fichier ou dossier de ce type (sorry for the french :) ) > It would have been far more useful had you translated the error

Re: [R] Delta in time series

2009-06-10 Thread christiaan pauw
Or x=c("2009-03-09 12:00:00","2009-03-09 13:30:00") y=data.frame(x) attach(y) x=as.POSIXlt(x) x[1]-x[2] On Wed, Jun 10, 2009 at 5:04 AM, koj wrote: > > > > > > I have time data in the following format: > > > > 2009-03-09 12:00:00 > > 2009-03-09 13:30:00 > > > > > [[alternative HTML v

Re: [R] by and by: using two indices in by() or tapply()

2009-06-10 Thread Henrique Dallazuanna
Try this: tapply(starttime,list(submitdate, surveyor),min) On Wed, Jun 10, 2009 at 4:20 PM, christiaan pauw wrote: > Hi everyone > I want to apply a function by two indices. > > I have a number of surveyors submitting questionnaires. I want to check the > time of the first submission for the da

[R] by and by: using two indices in by() or tapply()

2009-06-10 Thread christiaan pauw
Hi everyone I want to apply a function by two indices. I have a number of surveyors submitting questionnaires. I want to check the time of the first submission for the day for each surveyor and also see a NA is no submission was done on a particular day. This generates a sample of the data: sta

[R] tracking progress of loading large dataset into R for updating progress bar

2009-06-10 Thread Harsh
Hello UseRs, I am creating a GUI application in R using the RGtk2 library. I have incorporated a progress bar which I want to refresh periodically in keeping with the progress/completion of the read.csv function. I would like to show the progress bar in animation (pulsing of the bar) for as long a

Re: [R] Extracting Sequence Data from a Vector

2009-06-10 Thread David Winsemius
On Jun 10, 2009, at 1:28 PM, Eric Vander Wal wrote: Thanks in advance. I have a vector of numbers which contain sections that are sequences which increase by a value of 1 followed by a gap in the data and then another sequence occurs, etc: x<-c(1:3, 6: 7, 10:13) From the vector I need to

Re: [R] rgl vertices

2009-06-10 Thread Duncan Murdoch
On 6/10/2009 1:44 PM, kapo coulibaly wrote: I'm trying to make sense of the following example in the package rgl: vertices <- c( -1.0, -1.0, 0, 1.0, 1.0, -1.0, 0, 1.0, 1.0, 1.0, 0, 1.0, -1.0, 1.0, 0, 1.0 ) indices <- c( 1, 2, 3, 4 ) open3d() wire3d( qmesh3d(vert

[R] rgl vertices

2009-06-10 Thread kapo coulibaly
I'm trying to make sense of the following example in the package rgl: vertices <- c( -1.0, -1.0, 0, 1.0, 1.0, -1.0, 0, 1.0, 1.0, 1.0, 0, 1.0, -1.0, 1.0, 0, 1.0 ) indices <- c( 1, 2, 3, 4 ) open3d() wire3d( qmesh3d(vertices,indices) ) One would think that each vert

Re: [R] Extracting Sequence Data from a Vector

2009-06-10 Thread baptiste auguie
jim holtman wrote: try this: Oh well, i spent the time writing this so i might as well post my (almost identical) solution, x<-c(1:3, 6: 7, 10:13) breaks = c(TRUE, diff(x) != 1) data.frame(start = x[breaks], length = tabulate(cumsum(breaks))) Hoping this works, baptiste x [1

Re: [R] Extracting Sequence Data from a Vector

2009-06-10 Thread jim holtman
try this: > x [1] 1 2 3 6 7 10 11 12 13 > # find breaks > breaks <- c(FALSE, diff(x) != 1) > # now create matrix with groupings (just for visual) > z <- data.frame(x, cumsum(breaks)) > # create list with first element of each seq and the length > t(sapply(split(z, z[,2]), function(b) c(b[1,1]

[R] Extracting Sequence Data from a Vector

2009-06-10 Thread Eric Vander Wal
Thanks in advance. I have a vector of numbers which contain sections that are sequences which increase by a value of 1 followed by a gap in the data and then another sequence occurs, etc: x<-c(1:3, 6: 7, 10:13) From the vector I need to extract 2 items of information A) the first number in t

Re: [R] Creating a specific skewed distribution

2009-06-10 Thread Ravi Varadhan
There are actually two roots to your equation: 0.329 and 1.385. f <- function(x) (2*gamma(1+1/x))^x + log (0.10) x <- seq(0.1, 5, length=500) plot(x, fn(x), type="l") abline(h = 0, lty=2, col=2) Ravi. ---

Re: [R] is it possible to combine multiple barplots?

2009-06-10 Thread Ben Bolker
philipp schmidt-3 wrote: > > i am working with two sets of likert scale type (4 distinct values) data: > > dataA <- rep(1:4, c(3,2,2,4)) > dataB <- rep(1:4, c(5,4,3,2)) > > i can now (bar)plot both of these separately and compare the > distributions. > > plot(table(dataA), type='h') > plot(t

Re: [R] Analisys in Multidimensional contingency tables

2009-06-10 Thread Tobias Verbeke
Hi José, Hi everyone, Im trying to make an analysis of multidimensional contingency tables using R. I' working with the Agresti example where you have the data from 3 categories. The thing is how can I do the analisys using the G2 statistics. Somebody can send me an Idea? Please find below a l

Re: [R] is it possible to combine multiple barplots?

2009-06-10 Thread Philipp Schmidt
Thank you for the helpful reply! I am relatively new to R (the software and the community) and was not aware of the example galler. Now I am. The example you found looks very close to what I am trying to do and I should be able to modify it. Best - P On Tue, Jun 9, 2009 at 4:45 PM, Titus von der

Re: [R] Predict GARCH

2009-06-10 Thread bogaso.christofer
Suppose the GARCH(1,1) equation is : Sigma[t]^2 = w + a* Sigma[t-1]^2 + b*r[t-1]^2 One step ahead forecast : Sigma[t+1]^2 = w + a* Sigma[t]^2 + b*r[t]^2 All informations are available here Two step ahead forecast : Sigma[t+2]^2 = w + a* Sigma[t+1]^2 + b*r[t+1]^2 Here r[t+1] is not known at ti

[R] Analisys in Multidimensional contingency tables

2009-06-10 Thread José Ignacio Bustos Melo
Dear R-list, Hi everyone, Im trying to make an analysis of multidimensional contingency tables using R. I' working with the Agresti example where you have the data from 3 categories. The thing is how can I do the analisys using the G2 statistics. Somebody can send me an Idea? I attach the program

Re: [R] Two-sided log axis

2009-06-10 Thread David Winsemius
On Jun 10, 2009, at 12:23 PM, David Winsemius wrote: I would not have called such an axis "logarithmic" since the logarithm function is bounded below at 0, (I meant to say that arguments to log are bounded at zero.) but I think that what you seek will be found among the examples that acco

Re: [R] Two-sided log axis

2009-06-10 Thread David Winsemius
I would not have called such an axis "logarithmic" since the logarithm function is bounded below at 0, but I think that what you seek will be found among the examples that accompany Sarkar's book, chapter 8, figures 8.3 - 8.5: http://lmdvr.r-forge.r-project.org/figures/figures.html On Jun

[R] Two-sided log axis

2009-06-10 Thread John Wiedenhoeft
Hi, I have two curves that are best displayed using a logarithmic y-axis. I want to plot the difference of these curves, which means I would need a log scaling on both the negative and the positive side (i.e. the y-axis should be -100 -10 -1 0 1 10 100). Zero values should not be discarded. Is

Re: [R] Creating a specific skewed distribution

2009-06-10 Thread Ravi Varadhan
Here is one way to solve the equation: require(BB) f <- function(x) (2*gamma(1+1/x))^x + log (0.10) ans <- dfsane(par=1, fn=f) ans Ravi. --- Ravi Varadhan, Ph.D. Assistant P

Re: [R] Creating a specific skewed distribution

2009-06-10 Thread David Arnold
Etienne et al, This is exactly what I need. So I gave it an algebraic try and set: Mean=30=b*gamma(1+1/a), solve for b and substitute into F(60)=0.10. After a little algebra, this left me with [ 2*gamma(1+1/a) ]^a = -ln(0.10) Now, I don't think this has a closed form solution, at least not

Re: [R] Using yum to install R-2.9

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 9:53 AM, Saptarshi Guha wrote: Hello, On Fedora 8, yum install R , installs R-2.6. I dont have much experience with yum, how do change the repos(?) to install R-2.9? Thank you Saptarshi Upgrade to a still supported version of Fedora. Fedora 8 went EOL back in January,

Re: [R] SSOAP failing

2009-06-10 Thread Olivier Cailloux
Duncan Temple Lang a écrit : Olivier Cailloux wrote: Duncan Temple Lang a écrit : Olivier Cailloux wrote: Dear list, Sorry about that, my e-mail has been sent too soon by mistake (also from an incorrect exp. address). I was planning to add further details. So I'm running Debian Lenny.

Re: [R] Delta in time series

2009-06-10 Thread Gabor Grothendieck
Try this: > library(zoo) > Lines <- "2009-03-09 12:00:00,1 + 2009-03-09 13:30:00,2" > z <- read.zoo(textConnection(Lines), sep = ",", tz = "") > 1/frequency(as.zooreg(z)) [1] 5400 noting that 5400 seconds is 1.5 hours. On Wed, Jun 10, 2009 at 5:04 AM, koj wrote: > > Hi all, > > I have time data

Re: [R] graphically representing frequency of words in a speech?

2009-06-10 Thread Brown, Tony Nicholas
Yihui, This is quite impressive, thanks for helping me think about how to make tag clouds in R. Tony -Original Message- From: Yihui Xie [mailto:xieyi...@gmail.com] Sent: Wednesday, June 10, 2009 3:15 AM To: Brown, Tony Nicholas Cc: r-help@r-project.org Subject: Re: [R] graphically repr

Re: [R] Delta in time series

2009-06-10 Thread koj
koj wrote: > > Hi all, > > I have time data in the following format: > > 2009-03-09 12:00:00 > 2009-03-09 13:30:00 > > Now I want to compute the delta between the two time points, which results > in this example in 1,5 h. I tried this via "ts" and the related functions > but so far without s

[R] R: Best way to plot a Matrix of all possible pair combinations

2009-06-10 Thread suparna mitra
Hallo R Users, Please help I have some distance matrix data like > M[1:10,] [,1] [,2] [,3] [,4] [,5] [,6] [1,] 0.875 0.500 0.500 0.375 0.625 0. [2,] 0.8928571 1.000 0.000 0.8928571 0.1071429 0. [3,] 0.8928571 1.000

[R] Delta in time series

2009-06-10 Thread koj
Hi all, I have time data in the following format: 2009-03-09 12:00:00 2009-03-09 13:30:00 Now I want to compute the delta between the two time points, which results in this example in 1,5 h. I tried this via "ts" and the related functions but so far without sucess. Can anybody help me? Thank y

[R] Best way to plot a Matrix of all possible pair combinations

2009-06-10 Thread suparna mitra
Hallo R Users, I have some distance matrix data like > M[1:10,] [,1] [,2] [,3] [,4] [,5] [,6] [1,] 0.875 0.500 0.500 0.375 0.625 0. [2,] 0.8928571 1.000 0.000 0.8928571 0.1071429 0. [3,] 0.8928571 1.000 0.0

[R] GeoXp package

2009-06-10 Thread Poizot Emmanuel
Dear all, I would like to use GeoXp package under Ubuntu Jaunty. I did install the required package GeoXp, for which I had to install before rgdal package. So when done, I want to load the library (library(GepXp), I got the error when GeoXP want to load rgdal package: > library(sp) > library(

[R] checking and building ROracle on OS X

2009-06-10 Thread Rajarshi Guha
Hi, I'm running R 2.9.0 (from the DMG) on OS X 10.5 and am trying to get ROracle 0.5-9 to check and build. I have installed the full Oracle installation (10.2.0.4.0). The problem I'm facing is that I need to compile ROracle.so as 32 bit, but my environment needs to point to the 64 bit Oracle libs

Re: [R] How to get the unique pairs of a set of pairs dataframe ?

2009-06-10 Thread jim holtman
?combn > x [1] "i1" "i2" "i3" "i4" "i5" > combn(x,2) [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] "i1" "i1" "i1" "i1" "i2" "i2" "i2" "i3" "i3" "i4" [2,] "i2" "i3" "i4" "i5" "i3" "i4" "i5" "i4" "i5" "i5" > On Wed, Jun 10, 2009 at 10:47 AM, Moumita Das wrote: > Hi friends, > Pleas

Re: [R] How to get the unique pairs of a set of pairs dataframe ?

2009-06-10 Thread Henrique Dallazuanna
Try this: do.call(rbind, apply(combn(names(x), 2), 2, function(n)expand.grid(x[,n[1]], x[,n[2]]))) On Wed, Jun 10, 2009 at 11:47 AM, Moumita Das wrote: > Hi friends, > Please can anyone help me with an easier solution of doing the below > mentioned

[R] Using yum to install R-2.9

2009-06-10 Thread Saptarshi Guha
Hello, On Fedora 8, yum install R , installs R-2.6. I dont have much experience with yum, how do change the repos(?) to install R-2.9? Thank you Saptarshi __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read t

[R] How to get the unique pairs of a set of pairs dataframe ?

2009-06-10 Thread Moumita Das
Hi friends, Please can anyone help me with an easier solution of doing the below mentioned work. Suppose i have a dataset like this:--- i1 i2 i3 i4 i5 1 7 13 1 2 2 8 14 2 2 3 9 15 3 3 4 10 16 4 4 5 11 17 5 5 6 12 18 6 7 *i1,i2,i3,i4,i5 are my items.I am able to find all

[R] MCMC validity question

2009-06-10 Thread Thomas Mang
Hello, I have quite a tough problem, which might be able to be solved by MCMC. I am fairly new to MCMC (in the learning process) - so apologize if the answer is totally obvious, and any hints, links etc are greatly appreciated. I'll illustrate the problem in a version cut-down to the essentia

Re: [R] Creating a specific skewed distribution

2009-06-10 Thread Etienne B. Racine
You could also make some algebra. e.g. : ?rweibull gives the formula of the mean and of the cumulative distribution function in the Details section. So using your known parameters (i.e. mean=30 and p(10)=.10, i.e. cumulative function(10) =.90), I think it is sufficient to determine the exact val

Re: [R] Merge data frame and keep unmatched

2009-06-10 Thread Gabor Grothendieck
Try: merge(completedf, partdf, all.x = TRUE) or library(sqldf) # see http://sqldf.googlecode.com sqldf("select * from completedf left join partdf using(beta, alpha)") On Wed, Jun 10, 2009 at 9:56 AM, Etienne B. Racine wrote: > > Hi, > > With two data sets, one complete and another one partial,

Re: [R] Merge data frame and keep unmatched

2009-06-10 Thread Marc Schwartz
On Jun 10, 2009, at 8:56 AM, Etienne B. Racine wrote: Hi, With two data sets, one complete and another one partial, I would like to merge them and keep the unmatched lines. The problem is that merge() dosen't keep the unmatched lines. Is there another function that I could use to merge

[R] Merge data frame and keep unmatched

2009-06-10 Thread Etienne B. Racine
Hi, With two data sets, one complete and another one partial, I would like to merge them and keep the unmatched lines. The problem is that merge() dosen't keep the unmatched lines. Is there another function that I could use to merge the data frames. Example: completedf <- expand.grid(alpha=lett

Re: [R] Creating a specific skewed distribution

2009-06-10 Thread Mike Lawrence
With skewed unimodal distributions, the mode can't equal the mean, so assuming you want the mean to be around 30, I find that a weibull function can get close to what you want: > mean(rweibull(1e5,1.5,33)) [1] 29.77781 > pweibull(60,1.5,33) [1] 0.9138475 I'm sure you can play with the parameters

Re: [R] Comparing R and SAS

2009-06-10 Thread Terry Therneau
Satish, There are nearly as many opinions as people on this question. So accept these as my views only. 1. I have written S packages, SAS procedures and SAS macros over my career. S was specifically designed for extensibility and it shows. The ratio of time to get a new statistical i

Re: [R] Problem : solving a equation with R , fail with uniroot function

2009-06-10 Thread Ben Bolker
yann lancien wrote: > > Thanks for your help ! > I got another problem with my function : > test <- function(x,bb0=-3,bb1=5,c0=2,r0=0) { > ((exp(c0-r0)*(bb0+x)*(bb1-x))/((bb0+x+1)*(bb1-x-1))-1)} > > With this : > curve(test(x),from=-10,to=10) > > we can see that there are 2 roots : one in [

[R] (sem assunto)

2009-06-10 Thread Daniel Mail
hello, i was trying to predict values for a garch, so i did: predict(fitgarch,n.ahead = 20) but this doesn't work. Someone can tell me how to get the 20 values ahead of a garch model. thanks in advance _ Obtenh

[R] Predict GARCH

2009-06-10 Thread Daniel Mail
hello, i was trying to predict values for a garch, so i did: predict(fitgarch,n.ahead = 20) but this doesn't work. Someone can tell me how to get the 20 values ahead of a garch model. thanks in advance _ O Windows

Re: [R] arima modeling for multiple time series

2009-06-10 Thread David Winsemius
An R Site Search on the obvious strategy "arima Gilbert" produces two hits of which the first is: dse-package {dse1} On Jun 10, 2009, at 9:13 AM, Erin Hodgess wrote: Dear R People: Is there a package for arima modeling of multiple time series, please? I think that Dr. Paul Gilbert may have

Re: [R] poly regression

2009-06-10 Thread Ravi Varadhan
To get the result that you were expecting, use the following (which uses the raw polynomial a + bx + cx^2 rather than the orthogonal polynomial of degree 2): lm(y~poly(x,2, raw=TRUE)) Ravi. --- Ravi Varadhan, Ph.D.

Re: [R] plot two variograms on a same graph

2009-06-10 Thread Paul Hiemstra
Hi, It is possible, but without you specifying in which pacakge you are going to fit the variograms it is hard for us to provide an example. And what do you mean by variogram, is that the sample variogram or the fitted variogram model, or both? Try and keep to the posting guide next time to m

[R] arima modeling for multiple time series

2009-06-10 Thread Erin Hodgess
Dear R People: Is there a package for arima modeling of multiple time series, please? I think that Dr. Paul Gilbert may have one, but I'm drawing a blank on the package name. Thanks in advance, Sincerely, Erin -- Erin Hodgess Associate Professor Department of Computer and Mathematical Science

Re: [R] ggplot, qplot: alpha channel for colors corresponding to factor

2009-06-10 Thread Marianne Promberger
Many thanks for the quick reply! > d1 <- data.frame(Goodall=c(rep(1:3,5)), Better.adapt = > c(rep(1,7),rep(2,8)),Second.adapt=c(rep(1:5,3))) > library(ggplot2) > ggplot(d1, aes(x= Goodall, y = Better.adapt, colour=Second.adapt)) + > geom_jitter(alpha = 0.2) + scale_colour_gradient(low = "white",

Re: [R] filled.contour as image

2009-06-10 Thread David Winsemius
The image function in package Matrix plots a color legend by default. Searching on what seemed like the obvious strategy "image legend" in R Site Search would have identified this and a huge number of other alternatives, of which Lemon's color2D.matplot is the tenth. -- David Winsemius On

Re: [R] plot two variograms on a same graph

2009-06-10 Thread ONKELINX, Thierry
Dear Damien, I tend do use ggplot2 for more advanced plotting. You only have to create a dataframe with all the data you need. Here are some examples. library(gstat) library(ggplot2) data(meuse) coordinates(meuse) = ~x+y g1 <- gstat(id = "Raw", formula = lo

Re: [R] "R CMD check" does not find a mistake

2009-06-10 Thread Martin Maechler
> "MM" == Martin Maechler > on Wed, 10 Jun 2009 08:50:46 +0200 writes: > "CG" == Christophe Genolini > on Tue, 09 Jun 2009 16:17:15 +0200 writes: CG> Hi the list, I build a package. They was a mistake in CG> it, but R CMD check did not find it. Is that normal ?

Re: [R] ggplot, qplot: alpha channel for colors corresponding to factor

2009-06-10 Thread ONKELINX, Thierry
Dear Marianne, If find that a bit easier with ggplot() instead of qplot() d1 <- data.frame(Goodall=c(rep(1:3,5)), Better.adapt = c(rep(1,7),rep(2,8)),Second.adapt=c(rep(1:5,3))) library(ggplot2) ggplot(d1, aes(x= Goodall, y = Better.adapt, colour=Second.adapt)) + geom_jitter(alpha = 0.2) + scale

[R] plot two variograms on a same graph

2009-06-10 Thread damien landais
Hi, I would know how to plot two variograms on a same graph. I can plot one by one but I would draw both on the same one. Is it possible? Do i need any special package? Thanks! Cordialement Damien Landais __ R-help@r-project.org mailing list https://s

Re: [R] filled.contour as image

2009-06-10 Thread Jim Lemon
Muri Soares wrote: Hi, Is there a way to make the filled.contour() function produce a plot similar to the image() function? i.e. not have smooth contours but rather distinct "squares" corresponding to the different cells of the matrix. The reason I ask is because since image doesn't have an o

[R] ggplot, qplot: alpha channel for colors corresponding to factor

2009-06-10 Thread Marianne Promberger
Hi, I have a qplot like the one in the minimal example below, except I also have faceting like this: qplot(jitter(Goodall),jitter(Better.adapt),colour=Second.adapt,facets=~Pol,data=d1) and with the real data I get quite a lot of overplotting, so I would like to add an alpha channel. In addition

Re: [R] isolating Hour and minute form date and time

2009-06-10 Thread Allan Engelhardt
There is no class for times only in R. Your best bet is probably a difftime, e.g. time <- difftime(posix.date, as.Date(posix.date), units="secs") Allan. christiaan pauw wrote: Hi everybody. I have a dataframe that contains a factor with the date information in the format like in the example

Re: [R] Using ADF.Test

2009-06-10 Thread Wacek Kusnierczyk
Achim Zeileis wrote: [...] > is.vector(as.vector(...)) is not necessarily TRUE. Consider > > x <- cars[, 1, drop=FALSE] > is.vector(x) > is.vector(as.vector(x)) > identical(x, as.vector(x)) interesting. i wonder why as.vector does not give, at the very least, a warning when the result

Re: [R] isolating Hour and minute form date and time

2009-06-10 Thread Gabor Grothendieck
Try this and see R News 4/1 for more. > now <- Sys.time(); now [1] "2009-06-10 07:26:23 EDT" > library(chron) > ch <- as.chron(format(now)) > dd <- dates(ch); dd; dd+1 day 06/10/09 day 06/11/09 > tt <- times(ch) - times(dd); tt; tt+1/24 day 07:26:23 day 08:26:23 On Wed, Jun 10, 20

[R] isolating Hour and minute form date and time

2009-06-10 Thread christiaan pauw
Hi everybody. I have a dataframe that contains a factor with the date information in the format like in the example below: "2009/05/12 11:22:31 AM" I have been able to convert it to POSIXt using strptime Now I want to print only the date as one vector and the time in another vector but they must

[R] help with package "simsalabim"

2009-06-10 Thread mauede
I have attached a text file representing the centralized amplitude of a signal, sampled at 30Hz, whose length N = 6922 My goal is to remove the trend. I am using package "simsalabim". I ran command decompSSA with L = length(Amps)/5 The reason is that I have SSA/MTM toolkit running in Mac/OS.

Re: [R] Using ADF.Test

2009-06-10 Thread Achim Zeileis
On Wed, 10 Jun 2009, matifou wrote: ehxpieterse wrote: Hi, I am quite new to R and would appreciate some guidance, if possible. I have imported a csv file: spread <- read.csv("Spread.csv") I get the following error when I try to run adf.test: adf.test(spread,alternative = c("stationary", "

Re: [R] R on EC2 and R CMD javareconf

2009-06-10 Thread Allan Engelhardt
Java on Fedora 8 is a little funny so my guess is that is where the problem is (or that you are missing the Java development (*-devel) packages). I am (right now) building an Amazon image with Fedora 11 on x86_64 with R (and the "Engineering and Scientific" group) installed: let me know if you

  1   2   >