[R] reading and parsing gzipped files

2008-09-05 Thread Dmitriy Skvortsov
Hi all,I have large compressed text tab delimited files, I am trying to write efficient function to read them, I am using gzfile() and readLines() zz - gzfile(exampl.txt.gz, r) # compressed file system.time(temp1-readLines(zz )) close(zz) which work fast, and create vector of strings. The

Re: [R] question on FARIMA innovationsIn-Reply-To=[EMAIL PROTECTED]

2008-09-05 Thread Tony Cricenti
Hi Ferebee, I am also working on a similar problem. Have you solved it? I am trying to write a function to to determine the innovations. However, I think that the Farma package may do this. I haven't succeeded in getting Farma to work. It requires OX. Can you let me know if you have made any

Re: [R] isoMDS and dist

2008-09-05 Thread Prof Brian Ripley
On Thu, 4 Sep 2008, Carolyn A. Pucko wrote: I am starting with a matrix in which rows are vegetation plots and columns are various characteristics including ID# and elevation. I removed elevation and ID columns to avoid having those characteristics influence the distances between points

Re: [R] how to deal with NaN in boot object

2008-09-05 Thread Prof Brian Ripley
On Fri, 5 Sep 2008, Jinsong Zhao wrote: Hi there, I use boot() to do bootstrap simulation on my statistic, I get a boot object, named obj. For certain reasons, there are some NaN in obj$t. Now, I hope to get confidence interval using boot.ci(), it give the following error: Error in if

Re: [R] algorithm to create unique identifiers

2008-09-05 Thread Prof Brian Ripley
For a much simpler solution that does always work for numbers, see unique's methods for matrices and data frames. On Thu, 4 Sep 2008, Henrik Bengtsson wrote: On Thu, Sep 4, 2008 at 8:44 PM, Ralph S. [EMAIL PROTECTED] wrote: Hi all, I am trying to create a unique identifier for each row,

Re: [R] Trouble with R CMD check: I can't seem to get dependencies right (maybe I'm using R_LIBS incorrectly?)

2008-09-05 Thread Prof Brian Ripley
'Writing R Extensions' does say @quotation Note @code{R CMD check} and @code{R CMD build} run @R{} with @option{--vanilla}, so none of the user's startup files are read. If you need @env{R_LIBS} set (to find packages in a non-standard library) you will need to set it in the environment. @end

Re: [R] how to write a escape sequences in to a file

2008-09-05 Thread Prof Brian Ripley
A newline is \n. So hai \nhru. On Fri, 5 Sep 2008, Kurapati, Ravichandra (Ravichandra) wrote: Hi Str1-hai Str2-hru I want to write these 2 strings in a file separated by newline. How can I get this. Thanks K.Ravichandra

Re: [R] reading and parsing gzipped files

2008-09-05 Thread Prof Brian Ripley
On Thu, 4 Sep 2008, Dmitriy Skvortsov wrote: Hi all,I have large compressed text tab delimited files, I am trying to write efficient function to read them, I am using gzfile() and readLines() zz - gzfile(exampl.txt.gz, r) # compressed file system.time(temp1-readLines(zz )) close(zz)

[R] Odp: Help for par(mfrow)

2008-09-05 Thread Petr PIKAL
Hi see from plot.boot help page Side Effects All screens are closed and cleared and a number of plots are produced on the current graphics device. Screens are closed but not cleared at termination of this function. You need to change a behaviour of this function what shall not be simple. Or

Re: [R] restricted bootstrap

2008-09-05 Thread ONKELINX, Thierry
Grant, Have you considered a gls model instead of a lm model? In a gls model one can model the correlation between the measures. So you won't need to select a subset of your data. You can kind gls in the nlme package. HTH, Thierry

[R] Add marks to a point pattern

2008-09-05 Thread Vanessa Santos
My name is Vanessa and I am from Spain.I have in Excel a list of children that go and don´t go to the dentist, and I want to add these categorical marks to the point pattern in package spatstat.How can I do it? Thanks for your help. [[alternative HTML version deleted]]

[R] Package for Tidying-up R-code

2008-09-05 Thread Gundala Viswanath
Dear all, Is there any such package? I am thinking of something equivalent to Perl::Tidy. For example with VI editor one can visual highlight a portion of Perlcode and then issue the command: !perltidy then the code will be automatically arranged. - Gundala Viswanath Jakarta - Indonesia

Re: [R] Package for Tidying-up R-code

2008-09-05 Thread Dimitris Rizopoulos
check Section 3.1 of the `Writing R Extensions' manual. I hope it helps. Best, Dimitris Gundala Viswanath wrote: Dear all, Is there any such package? I am thinking of something equivalent to Perl::Tidy. For example with VI editor one can visual highlight a portion of Perlcode and then

[R] Upgrade to R 2.7.2 from Debian Repository

2008-09-05 Thread Tom La Bone
I am running R 2.7.1 on an eeepc with the standard Xandros Linux. I install/upgrade R binaries using synaptic from the http://cran.r-project.org/bin/linux/debian/etch-cran/ repository. R 2.7.2 does not appear to be available from this repository. Will it be available soon or is there another

[R] controlling lattice plot ticks with relation=free

2008-09-05 Thread Richard . Cotton
How do you persuade lattice to draw tick marks on both the left and right side of the y-axis, when relation=free in the scales component? #Ticks appear on both sides histogram(~height|voice.part, data=singer) ##Ticks only on left histogram(~height|voice.part, data=singer,

Re: [R] Fitted probabilities in conditional logit regression

2008-09-05 Thread Gavin Simpson
On Sun, 2008-08-31 at 09:49 -0400, Min Chen wrote: Dear R-help, I'm doing conditional logit regression for a discrete choice model. I want to know whether there's a way to get the fitted probabilities. In Stata, predict works for clogit, but it seems that in R predict does not.

Re: [R] how to write a escape sequences in to a file

2008-09-05 Thread Henrique Dallazuanna
Try this: cat(Str1, Str2, file = out.txt, sep = \n) On Fri, Sep 5, 2008 at 2:21 AM, Kurapati, Ravichandra (Ravichandra) [EMAIL PROTECTED] wrote: Hi Str1-hai Str2-hru I want to write these 2 strings in a file separated by newline.

Re: [R] Plotting using 'if' statements

2008-09-05 Thread Steve Murray
Sorry! Hopefully just one more question! I'm now trying to plot columns 3 and 6. I've tried: plot(January[3:6]) ...but this plots columns 4 and 5 too! I've also tried: plot(January[3],January[6]) plot(January[3,6]) plot(January[3]:January[6]) But these don't produce the right results

Re: [R] Plotting using 'if' statements

2008-09-05 Thread Henrique Dallazuanna
Use this: plot(January[c(3, 6)]) On Fri, Sep 5, 2008 at 8:52 AM, Steve Murray [EMAIL PROTECTED] wrote: Sorry! Hopefully just one more question! I'm now trying to plot columns 3 and 6. I've tried: plot(January[3:6]) ...but this plots columns 4 and 5 too! I've also tried:

[R] how to draw the legend about color from 3d picture

2008-09-05 Thread yk
I have drawed a picture with persp, it's 3d map with different color, indicate different altitude. In gnuplot, the corresponding command 'splot' will generate a picture beside to indicate the relationship between color and altitude. But in R, how to draw it? I have read the manual of legend, but

[R] Orthogonalization algorithms

2008-09-05 Thread Williams, Robin
Hi, I have eight vectors that I would like to orthogonalize preferably using R. The vectors are of considerable length, however due to their nature I know they satisfy the conditions needed to apply the Gram-Schmidt algorithm. Before I embark on some R coding, I wanted to check that there is no

Re: [R] Orthogonalization algorithms

2008-09-05 Thread Williams, Robin
Please ignore this, it appears I have found what I'm looking for in the far package. Robin Williams Met Office summer intern - Health Forecasting [EMAIL PROTECTED] -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Williams, Robin Sent: Friday,

[R] Error: can not allocate vector of 117.3 Mb

2008-09-05 Thread ram basnet
Hi R users,   I am doing multiscale bootstrapping for clustering through pvclust package. I have large data set (observations 182 and variables 5546). When i tried to make bootstrapping, then i got message as Bootstrap (r = 0.5)Error: cannot allocate vector of size 117.3 Mb. I am

Re: [R] Error: can not allocate vector of 117.3 Mb

2008-09-05 Thread Uwe Ligges
ram basnet wrote: Hi R users, I am doing multiscale bootstrapping for clustering through pvclust package. I have large data set (observations 182 and variables 5546). When i tried to make bootstrapping, then i got message as Bootstrap (r = 0.5)Error: cannot allocate vector of

Re: [R] Plotting using 'if' statements

2008-09-05 Thread Steve Murray
Thanks again for a very quick reply! It worked really well too! _ Discover Bird's Eye View now with Multimap from Live Search __ R-help@r-project.org mailing list

Re: [R] how to draw the legend about color from 3d picture

2008-09-05 Thread Duncan Murdoch
On 9/5/2008 8:06 AM, yk wrote: I have drawed a picture with persp, it's 3d map with different color, indicate different altitude. In gnuplot, the corresponding command 'splot' will generate a picture beside to indicate the relationship between color and altitude. But in R, how to draw it? I have

[R] Use of colour in plots

2008-09-05 Thread Steve Murray
Dear all, I have 3 datasets all of which share the same longitude and latitude values, which I'm looking to plot onto a scattergraph. The third dataset has values which can only be either '1' or '2'. So to incorporate all three datasets onto two axes, I'm wondering if I can plot dataset1 and

Re: [R] cluster a distance(analogue)-object using agnes(cluster)

2008-09-05 Thread Gavin Simpson
On Thu, 2008-09-04 at 11:28 +0200, Martin Maechler wrote: B == Birgitle [EMAIL PROTECTED] on Tue, 2 Sep 2008 03:02:31 -0700 (PDT) writes: B I try to perform a clustering using an existing dissimilarity matrix that I B calculated using distance (analogue) B I tried two

[R] Confidence Intervals on Hazard Plots

2008-09-05 Thread Alan Cox
Hello, Is it possible to create confidence intervals for hazard rates?  I'm creating two muhaz objects:  haz1 - muhaz(NumDaysCustomer[cRV==true],status[cRV==true]) haz2 - muhaz(NumDaysCustomer[cRV==false],status[cRV==false]) and plotting them.   There are many, many more observations in

[R] text processing for plots

2008-09-05 Thread David Carslaw
Hi R people, I want to write some functions to automate the plotting of some expressions that use some of the plotmath capabilities. An example is a string supplied to a plot call such as: plot(1, 1, ylab = pm10 (ug/m3)) This should actually appear like: plot(1, 1, ylab = expression(PM[10] *

Re: [R] Maximum likelihood estimation

2008-09-05 Thread Ravi Varadhan
Hi, You should re-write your function `fr' as follows: fr - function(par){ a - par[1] b - par[2] p - par[3] lambda - par[4] l - 0.5*(lambda + b*p + (1-p)*(lambda-b)) l^2 lambda*b*p delta - sqrt(abs(l^2 - b*p*lambda)) mt - a/p*(1-exp(-l*t)*cosh(delta*t)-(l-b*p)*exp(-t)*sinh(delta*t)/delta)

Re: [R] Error: can not allocate vector of 117.3 Mb

2008-09-05 Thread Tom La Bone
To see some useful discussions of this problem in various settings search R-Help for the phrase cannot allocate vector of size. Tom ram basnet wrote: Hi R users,   I am doing multiscale bootstrapping for clustering through pvclust package. I have large data set (observations 182 and

[R] Question about col.names in write.csv

2008-09-05 Thread Luz Milena Zea Fernandez
Dear support, I don't ignore col.names in write.csv. I want to write names for the firts row. How can I do? Thanks in advance __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] (with subject)

2008-09-05 Thread Dr Eberhard W Lisse
Oh, YES, thank you! This weekend I'll try and figure out how to plot these events on a 24 hour scale, i.e I'll aggregate the SQL query on the time But not on the date) to see how many of those fall outside of normal working hours :-)-O greetings, el On 05 Sep 2008, at 00:59 , Gabor

Re: [R] Use of colour in plots

2008-09-05 Thread John Kane
Here is an example doing the same type of thing. It should be easy enough to adapt. Good luck === x - runif(100, 0, 1) y - runif(100, 0, 1) z - data.frame(x,y) plot(subset(z, z$y =.5), col=red, ylim=c(min(z$y), max(z$y)), pch=16)

[R] Example on Maximum likelihood estimation using R

2008-09-05 Thread VincentLee
Hi all, I am very new to R too, but I read that R is powerful. May I know given a set of data, are there any simple examples on using mle() to estimate parameters of a lognormal and weibull distribution ? Hope to hear from you soon. Thank you Vincent Ravi Varadhan wrote: Hi, You

[R] using nls to fit a curve to data

2008-09-05 Thread jpl
Hi, I am trying to fit a curve to data. My command line is: model10=nls(offspring~((A*c^k)/gamma(k))*((degdays-alpha)^(k-1))*exp(-c*(degdays-alpha)), start=list(A=30,k=2,c=.018,alpha=131)) I get the error message: Error in numericDeriv(form[[3]], names(ind), env) : Missing

Re: [R] Use of colour in plots

2008-09-05 Thread Petr PIKAL
Hi [EMAIL PROTECTED] napsal dne 05.09.2008 16:24:35: Here is an example doing the same type of thing. It should be easy enough to adapt. Good luck === x - runif(100, 0, 1) y - runif(100, 0, 1) z - data.frame(x,y)

Re: [R] Density estimates in modelling framework

2008-09-05 Thread hadley wickham
Thanks for all your replies. The suggestions I got were: * gss * logspline * locfit I ended up using locfit because the interface was just right for my needs, and it was faster than the alternatives. Hadley On Fri, Aug 29, 2008 at 2:03 PM, hadley wickham [EMAIL PROTECTED] wrote: Hi

Re: [R] ggplot2: Changes to grobs not saved to file output

2008-09-05 Thread hadley wickham
Unfortunately it's not particularly easy in the current version. In the next version, you can do: p - qplot(wt, mpg, data=mtcars, colour=cyl) # Get the plot grob grob - ggplotGrob(p) # Modify it place grob - geditGrob(grob, gPath(strip,label), gp=gpar(fontface=bold)) # Draw it pdf(...)

[R] binary order combinations

2008-09-05 Thread Dimitri Liakhovitski
Dear all! I have a vector of names names-(V1, V2, V3,., V15) I could create all possible combinations of these names (of all lengths) using R: combos-lapply(1:15,function(x) {combn(names,x) }) I get a list with all possible combinations of elements of 'names' that looks like this (just the

Re: [R] binary order combinations

2008-09-05 Thread roger koenker
Does ?combos in the quantreg package do what you want? url:www.econ.uiuc.edu/~rogerRoger Koenker email[EMAIL PROTECTED]Department of Economics vox: 217-333-4558University of Illinois fax: 217-244-6678Champaign, IL 61820

Re: [R] controlling lattice plot ticks with relation=free

2008-09-05 Thread Richard . Cotton
How do you persuade lattice to draw tick marks on both the left and right side of the y-axis, when relation=free in the scales component? #Ticks appear on both sides histogram(~height|voice.part, data=singer) ##Ticks only on left histogram(~height|voice.part, data=singer,

[R] Time Series (attribute)

2008-09-05 Thread Oliver Bandel
Hello, what kind of advantages does R's time series offer? Would it be possible to use data with units? For example data from a real time series with certain sampling rates - could they be used so, that the sample-times are measured in millisceonds or microseconds, instead of an index of the

Re: [R] binary order combinations

2008-09-05 Thread Dimitri Liakhovitski
I am not sure it can do it. Besides, I ran a test of combos from quantreg: library(quantreg) H-1:3 test.combos-lapply(1:3,function(x) {combn(H,x) }) Every time I tried it crashed my R... :( Dimitri On 9/5/08, roger koenker [EMAIL PROTECTED] wrote: Does ?combos in the quantreg package do what

[R] Lowest k values of list

2008-09-05 Thread Markus Mühlbacher
Hi @ all, how do I get the largest or lowest k values of list? It must similar to the min() / max() function, but I just don't get it. Best wishes, Markus __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do

[R] Plot by column

2008-09-05 Thread Zhang Yanwei - Princeton-MRAm
Dear list, I have the following matrix. How can I make the following plot? 1. The x-axis has index 1:7, and the first column is plotted against index 1, second against 2, and so on. 2. I want the points from the left upper conner including the antidiagonal to be plotted with col=2, and the

Re: [R] Upgrade to R 2.7.2 from Debian Repository

2008-09-05 Thread Dirk Eddelbuettel
Tom, (That's a suitable question for r-sig-debian) On 5 September 2008 at 03:08, Tom La Bone wrote: | I am running R 2.7.1 on an eeepc with the standard Xandros Linux. I | install/upgrade R binaries using synaptic from the | http://cran.r-project.org/bin/linux/debian/etch-cran/ repository. R

Re: [R] Confidence Intervals on Hazard Plots

2008-09-05 Thread David Winsemius
On Sep 5, 2008, at 9:20 AM, Alan Cox wrote: Hello, Is it possible to create confidence intervals for hazard rates? I'm creating two muhaz objects: haz1 - muhaz(NumDaysCustomer[cRV==true],status[cRV==true]) haz2 - muhaz(NumDaysCustomer[cRV==false],status[cRV==false]) and plotting them.

[R] dealing with NAs in time series

2008-09-05 Thread Alexy Khrabrov
Certain timeseries I have had outliers, which I removed by assigning NA to their positions. Now acf() refuses to go to work. What's the right way to remove outliers from ts objects, and what are teh standard ways to interpolate NAs in them? Cheers, Alexy

Re: [R] Time Series (attribute)

2008-09-05 Thread Gabor Grothendieck
The zoo package can handle series with times of any class that is totally ordered and provides certain methods. That includes all common time classes and allows for you to define new time classes too. See library(zoo) ?zoo and the three vignettes (i.e. pdf documents) that come with it. On

Re: [R] Lowest k values of list

2008-09-05 Thread Jorge Ivan Velez
Dear Markus, Try this: # Data set set.seed(123) mylist=list(a=rnorm(10),b=rpois(15,10),f=rnorm(30,12,3)) mylist # min and max temp=lapply(mylist,function(x){ res=c(min(x),max(x)) names(res)=c('Min.','Max.') res } ) do.call(rbind,temp) Min. Max. a -1.265061 1.715065 b 3.00

Re: [R] Lowest k values of list

2008-09-05 Thread David Winsemius
On Sep 5, 2008, at 11:26 AM, Markus Mühlbacher wrote: Hi @ all, how do I get the largest or lowest k values of list? It must similar to the min() / max() function, but I just don't get it. Might depend on how you define high and low. Consider these experiments: z -

Re: [R] binary order combinations

2008-09-05 Thread Henrik Bengtsson
names - sprintf(V%d, 1:4); n - length(names); stopifnot(n = 32); # Theoretical upper limit x - matrix(intToBits(1:(2^n-1)), ncol=2^n-1); x - x[1:n,,drop=FALSE]; keys - apply(x, MARGIN=2, FUN=function(z) paste(names[as.logical(z)], collapse=:)); print(keys); [1] V1 V2 V1:V2

Re: [R] Lowest k values of list

2008-09-05 Thread jim holtman
Do you mean a vector? If so, head/tail will work for you: x - runif(10) x [1] 0.26550866 0.37212390 0.57285336 0.90820779 0.20168193 0.89838968 0.94467527 [8] 0.66079779 0.62911404 0.06178627 # lowest 5 head(sort(x), 5) [1] 0.06178627 0.20168193 0.26550866 0.37212390 0.57285336 # highest 5

Re: [R] binary order combinations

2008-09-05 Thread Dimitri Liakhovitski
Sorry, I misread it first. I tried: library(quantreg) test.combos-lapply(1:15,function(x) {combos(15,x) }) It gives me a list with an order that is somewhat different from before, but I am not sure it helps me much: [[1]] [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12]

Re: [R] Lowest k values of list

2008-09-05 Thread Jorge Ivan Velez
Dear Markus, I think that I missed something in my previous reply. Here is another approach using the first k values of each list: # Data set set.seed(123) mylist=list(a=rnorm(10),b=rpois(15,10),f=rnorm(30,12,3)) # Function to report the first k values k.values=function(x,k){ res=

Re: [R] binary order combinations

2008-09-05 Thread roger koenker
You need to read the help file ?combos, and then use it to do indexing of your objects, it only knows how to construct the integer combinations given a pair (n,p). url:www.econ.uiuc.edu/~rogerRoger Koenker email[EMAIL PROTECTED]Department of Economics vox:

Re: [R] how to draw the legend about color from 3d picture

2008-09-05 Thread Greg Snow
Look at the color.legend function in the plotrix package to see if it does what you want. You may want to use the layout function to split the graphics device into 2 sections, one for the persp plot and the other to hold the legend. Hope this helps, -- Gregory (Greg) L. Snow Ph.D. Statistical

[R] lm and time series.

2008-09-05 Thread rkevinburton
I did a ?lm and it said basically to be careful when using lm and a time series. But my question is probably more to do with my inexperience that anything. If I have a time series object 'ti' how do I write the formula? The response is the value at any particular time and the time is basically

Re: [R] binary order combinations

2008-09-05 Thread Dimitri Liakhovitski
Henrik, this is amazing! wow! Thank you so much! Dimitri On 9/5/08, Henrik Bengtsson [EMAIL PROTECTED] wrote: names - sprintf(V%d, 1:4); n - length(names); stopifnot(n = 32); # Theoretical upper limit x - matrix(intToBits(1:(2^n-1)), ncol=2^n-1); x - x[1:n,,drop=FALSE]; keys - apply(x,

Re: [R] lm and time series.

2008-09-05 Thread Gabor Grothendieck
The Time Series section in ?lm should be self explanatory. If you are using diff's and lag's then look at the dyn package. On Fri, Sep 5, 2008 at 12:25 PM, [EMAIL PROTECTED] wrote: I did a ?lm and it said basically to be careful when using lm and a time series. But my question is probably

Re: [R] Lowest k values of list

2008-09-05 Thread Greg Snow
In addition to the other responses, you may want to look at the 'partial' argument to sort. For large vectors it may speed things up to not sort everything if all you care about is the top and bottom few. Try: tmp - rnorm(100) plot( sort(tmp, partial=c(1,2,99,100) ) ) Hope this helps, --

Re: [R] Plot by column

2008-09-05 Thread Henrique Dallazuanna
You can try something like about this: r[upper.tri(r)] - NA matplot(t(r), lty = 1, type = 'p', pch = 1, ylim = c(0.4, 1.2), col = 'black') On Fri, Sep 5, 2008 at 12:27 PM, Zhang Yanwei - Princeton-MRAm [EMAIL PROTECTED] wrote: Dear list, I have the following matrix. How can I make the

[R] Adding a legend to R graph device with several plots (no to individual plots!)

2008-09-05 Thread Monica Pisica
Hi Nelson, I don't know if you got your answer or not but here it is my low-tech solution for what is worth. I like to do a layout as I want my graphs to be and add some space where I plot an invisible graph with dummy data and add the legend there. In this case I decided to put the legend on

[R] casting help please

2008-09-05 Thread davidr
I have a data.frame which I believe is melted already and am having trouble casting it to 'wide' format. It looks something like (x - data.frame(ticker=c(rep(A,5),rep(B,6)), date=c(1:5, 1:6), value=c(NA,100*exp(rnorm(10,0,.1) cast(x, date ~ ticker) # this does what I want with toy data

Re: [R] Question about col.names in write.csv

2008-09-05 Thread Julian Burgos
Hi Luz, No entiendo bien tu pregunta. Querés grabar una tabla con nombres en las columnas y tambien en la primera fila? Si es asi, tenés que asignarle los nombres a la tabla antes de grabar. Por ejemplo: mi.tabla=matrix(runif(30),ncol=3) colnames(mi.tabla)=c(A,B,C)

Re: [R] casting help please

2008-09-05 Thread hadley wickham
Hi David, Does getting rid of the missings help? prices - prices[complete.cases(prices), ] Also, you shouldn't need add.missing=TRUE - what are you trying to do? Hadley On Fri, Sep 5, 2008 at 12:12 PM, [EMAIL PROTECTED] wrote: I have a data.frame which I believe is melted already and am

Re: [R] casting help please

2008-09-05 Thread davidr
I think I just remembered that in a melted data.frame the values have to be called 'value' and tried renaming my third column so. Now it works (without add.missing). Thanks for this powerful piece of software! -- David (I was trying to convert a set of data in 'long' format to 'wide' format.

[R] upgraded maps database for italy?

2008-09-05 Thread livio spam
Dear UseRs, I'm using the library maps. I'm drawing maps of Italy. The map available for this library were prepared around *1989*: This italy database comes from the NUTS III (Tertiary Administrative Units of the European Community) database of the United Nations Environment Programme (UNEP)

Re: [R] upgraded maps database for italy?

2008-09-05 Thread Greg Snow
If I remember correctly, the maps package only has a few dedicated maps that works with it. The maptools package has similar (but not exactly the same) functionality and can work with shapefiles that are more commonly available. Maptools also integrates nicely with the sp and related packages

Re: [R] asscii2netcdf]

2008-09-05 Thread Philip Twumasi-Ankrah
Hi Marshall, This link provides very good directions and examples you can use. http://www.image.ucar.edu/GSP/Software/Netcdf/ A Smile costs Nothing  But Rewards Everything Happiness is not perfected until it is shared   -Jane

[R] boxplot including null info from dataframe, not with SQLite dataframe

2008-09-05 Thread Coey Minear
I have been trying to use R to gather some information from parsed log files (as part of examining some performance issues). I parsed the log files and put the data into an SQLite database, and then used RSQLite to load the data into R. The fields of interest are controller, action and

[R] comparing two files

2008-09-05 Thread Rajasekaramya
Hi there I have two object on is a vector T and the other is dataframe C. vector T has more no of rows when comapred with a dataframe Ccolumn[,2].I want to find the the missing rows in dataframe C.That is those values that are not matchig in dataframe C[,2] Kindly give me suggestion on how to

Re: [R] library/function that estimates parameters of well known distributions from empirical data?

2008-09-05 Thread Ben Bolker
Ted Byers r.ted.byers at gmail.com writes: I found this a few months ago, but for the life of me I can't remember what the function or package was, and I have had no luck finding it this week. I have found, again, the functions for working with distributions like Cauchy, F, normal, c.,

Re: [R] boxplot including null info from dataframe, not with SQLite dataframe

2008-09-05 Thread Ben Bolker
Coey Minear cminear at securecomputing.com writes: I have been trying to use R to gather some information from parsed log files (as part of examining some performance issues). I parsed the log files and put the data into an SQLite database, and then used RSQLite to load the data into R.

Re: [R] lm and time series.

2008-09-05 Thread rkevinburton
I am sorry but I looked at ?lm and could not see any guidance on writting a formula. If I have two arrays or a data set then I know how to do that (y ~ x) but for a time series I am not sure how to write y or x. Thank you. Kevin Gabor Grothendieck [EMAIL PROTECTED] wrote: The Time

Re: [R] comparing two files

2008-09-05 Thread John Kane
?which which(C[,2]!= T) # untested --- On Fri, 9/5/08, Rajasekaramya [EMAIL PROTECTED] wrote: From: Rajasekaramya [EMAIL PROTECTED] Subject: [R] comparing two files To: r-help@r-project.org Received: Friday, September 5, 2008, 2:57 PM Hi there I have two object on is a vector T and

Re: [R] comparing two files

2008-09-05 Thread jim holtman
?match T.v - sample(1:20) C.df - data.frame(a=1:10, b= sample(1:20, 10)) T.v [1] 10 12 9 4 14 11 19 2 18 5 16 6 7 17 8 20 1 13 3 15 C.df a b 1 1 10 2 2 17 3 3 8 4 4 5 5 5 2 6 6 16 7 7 19 8 8 7 9 9 18 10 10 14 # find the missing values

Re: [R] comparing two files

2008-09-05 Thread Jorge Ivan Velez
Hi there, See ?%in% Here is an example: x=sample(1:10) x [1] 2 1 10 5 4 7 3 6 8 9 y=sample(4:20) y [1] 17 16 18 10 8 19 4 5 11 13 12 14 20 6 7 9 15 x[x%in%y] # x values present in y [1] 10 5 4 7 6 8 9 HTH, Jorge On Fri, Sep 5, 2008 at 2:57 PM, Rajasekaramya

Re: [R] dealing with NAs in time series

2008-09-05 Thread stephen sefick
look at zoo na.approx this will interpolate in a couple of ways On Fri, Sep 5, 2008 at 11:28 AM, Alexy Khrabrov [EMAIL PROTECTED] wrote: Certain timeseries I have had outliers, which I removed by assigning NA to their positions. Now acf() refuses to go to work. What's the right way to remove

Re: [R] lm and time series.

2008-09-05 Thread stephen sefick
what do you want to do? On Fri, Sep 5, 2008 at 3:22 PM, [EMAIL PROTECTED] wrote: I am sorry but I looked at ?lm and could not see any guidance on writting a formula. If I have two arrays or a data set then I know how to do that (y ~ x) but for a time series I am not sure how to write y or

Re: [R] Package for Tidying-up R-code

2008-09-05 Thread Don MacQueen
I don't know what kind of tidying you want, but ESS within emacs is a possibility. -Don At 6:32 PM +0900 9/5/08, Gundala Viswanath wrote: Dear all, Is there any such package? I am thinking of something equivalent to Perl::Tidy. For example with VI editor one can visual highlight a portion

[R] Using R to generate reports

2008-09-05 Thread Bill Cunliffe
Hi all, I would like to generate nicely formatted reports on a daily basis. The reports would be a combination of charts and tables, generated in an environment such as R. Ideally, this would be an automated process. Does anyone know if this is feasible, and how I could achieve well

[R] Recall: Using R to generate reports

2008-09-05 Thread Bill Cunliffe
Bill Cunliffe would like to recall the message, Using R to generate reports. __ 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

Re: [R] lm and time series.

2008-09-05 Thread rkevinburton
I want to fit a function to time series. If I had: x - 1:4 y - 1:4 lm(y~x) This would fit a simple line to the four points. But if it is represented as a time series x - 1:4 t - ts(x) lm() So I have a time series in the object t. How do I write a formula for lm? What do I put in the

[R] Area of density

2008-09-05 Thread pragmatic
Hello! Please, anybody help me. Can I calculate area of density was created by: D - density(x) In other words I want to know area under curve 'plot(D)' and It's good to calculate area before and after 0 separately. -- View this message in context:

[R] Articles about comparision between R and others softwares

2008-09-05 Thread ricardo13
Hi Do you know some articles, papers, something than tell about comparision between R and others softwares statisticals. Thank You Ricardo -- View this message in context: http://www.nabble.com/Articles-about-comparision-between-R-and-others-softwares-tp19338210p19338210.html Sent from the R

Re: [R] upgraded maps database for italy?

2008-09-05 Thread Ray Brownrigg
The italy (and france) databases only exists in the maps package because somebody supplied me with the data in an appropriate format - latitude/longitude pairs separately for each polygon (provinces in this case). If you have the appropriate data for what you want i.e. updated provinces and

[R] Multiple Correspondence Analysis

2008-09-05 Thread Bill Vorias
Is there a way to get the coordinates from a plot of an MCA object? [[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

Re: [R] library/function that estimates parameters of well known distributions from empirical data?

2008-09-05 Thread Ted Byers
Thanks Ben That was the one I'd remembered but couldn't find. Mark Leeds also told me about DistributionFits(fBasics), which I hadn't seen. There seems to be only a little overlap between the two. Could I trouble you to expand on AIC (esp. what the function name and package is to apply it to

Re: [R] Multiple Correspondence Analysis

2008-09-05 Thread Jorge Ivan Velez
Dear Bill, See http://finzi.psych.upenn.edu/R/library/ade4/html/dudi.acm.html HTH, Jorge On Fri, Sep 5, 2008 at 5:00 PM, Bill Vorias [EMAIL PROTECTED]wrote: Is there a way to get the coordinates from a plot of an MCA object? [[alternative HTML version deleted]]

Re: [R] Using R to generate reports

2008-09-05 Thread Jorge Ivan Velez
Dear Bill, See http://www.statistik.lmu.de/~leisch/Sweave/ HTH, Jorge On Fri, Sep 5, 2008 at 5:40 PM, Bill Cunliffe [EMAIL PROTECTED] wrote: Hi all, I would like to generate nicely formatted reports on a daily basis. The reports would be a combination of charts and tables, generated

Re: [R] lm and time series.

2008-09-05 Thread stephen sefick
So you want time as the independent variable? Let's say that the units of y in your first example were seconds- couldn't you just use a regular lm and say that the units were seconds, minutes, or what ever? I am probably out of my league here, but I am just not understanding what it is that you

Re: [R] Area of density

2008-09-05 Thread Duncan Murdoch
On 05/09/2008 4:32 PM, pragmatic wrote: Hello! Please, anybody help me. Can I calculate area of density was created by: D - density(x) In other words I want to know area under curve 'plot(D)' That should be 1. and It's good to calculate area before and after 0 separately. That's harder,

[R] xls to csv conversion via WinXP's context menu?

2008-09-05 Thread Mark Na
Frequently I need to convert a .xls to a .csv (for import into R) and I do this by opening the file in excel and saving it as a csv. I would rather do this using WinXP's context menu (right click the xls, choose convert to csv) but I don't know of a utility that does this. Any ideas? Thanks,

Re: [R] Area of density

2008-09-05 Thread Rolf Turner
On 6/09/2008, at 8:32 AM, pragmatic wrote: Hello! Please, anybody help me. Can I calculate area of density was created by: D - density(x) In other words I want to know area under curve 'plot(D)' and It's good to calculate area before and after 0 separately. (1) You could use splinefun()

Re: [R] xls to csv conversion via WinXP's context menu?

2008-09-05 Thread Gabor Grothendieck
See ?xls2csv in the gdata package. On Fri, Sep 5, 2008 at 6:45 PM, Mark Na [EMAIL PROTECTED] wrote: Frequently I need to convert a .xls to a .csv (for import into R) and I do this by opening the file in excel and saving it as a csv. I would rather do this using WinXP's context menu (right

Re: [R] xls to csv conversion via WinXP's context menu?

2008-09-05 Thread Jorge Ivan Velez
Dear Mark, I think you don't need to convert your xls files into csv files to read them using R. There are several ways to read them such as the RODBC package and ?read.xls in gdata. Now, if you really want to do the conversion, try ?xls2csv in gdata as well. HTH, Jorge On Fri, Sep 5, 2008 at

[R] annotating objects in workspace

2008-09-05 Thread Alexy Khrabrov
Is there a way to associate descriptions with the objects in the workspace, and later retrieve them to know what the object was created for? Thanks, Alexy __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do

  1   2   >