Re: [R] sscanf equivalent

2005-10-09 Thread Paul Roebuck
On Fri, 7 Oct 2005, Prof Brian Ripley wrote: On Fri, 7 Oct 2005, Paul Roebuck wrote: I have a data file from which I need to read portions of data but data location/quantity can change from file to file. I wrote some code and have a working solution but it seems wasteful to have to do

[R] How to get the remaining vector after sampling a subset?

2005-10-09 Thread Xiao Shi
Hi , I have a vector,for example, x=rnorm(100) Then i rendom choose 20 of them. chosen=sample(x,20). And i want to get the remain values in x. Is there a quick way to go? Thanks in advance. [[alternative HTML version deleted]] __

Re: [R] How to get the remaining vector after sampling a subset?

2005-10-09 Thread Sundar Dorai-Raj
Xiao Shi wrote: Hi , I have a vector,for example, x=rnorm(100) Then i rendom choose 20 of them. chosen=sample(x,20). And i want to get the remain values in x. Is there a quick way to go? Thanks in advance. [[alternative HTML version deleted]] How about: x - rnorm(100) y -

Re: [R] How to get the remaining vector after sampling a subset?

2005-10-09 Thread Dimitris Rizopoulos
one way is to use: x[!x %in% chosen] I hope it helps. Best, Dimitris - Original Message - From: Xiao Shi [EMAIL PROTECTED] To: r-help@stat.math.ethz.ch Sent: Sunday, October 09, 2005 11:26 AM Subject: [R] How to get the remaining vector after sampling a subset? Hi , I have a

Re: [R] lm.ridge

2005-10-09 Thread Prof Brian Ripley
On Sat, 8 Oct 2005, Erin Hodgess wrote: Dear R People: I have a question about the lm.ridge function, please. In the example, there is one set of output values in the select function but another in the comment section. Am I missing something please? The values in the examples were

[R] Rmetrics fMultivar how to?

2005-10-09 Thread Benedict P. Barszcz
Hi Everybody, I am a total beginner at this so please bear with me. I downloaded by hand the file WIG20.txt (Warsaw Stock Exchange Index of 20 most important stocks). The format is this: Name,Date,Open,High,Low,Close,Volume WIG20,19940414,1000.00,1000.00,1000.00,1000.00,71600.000

[R] background color of xyplot

2005-10-09 Thread Marc Bernard
Dear All, I am wondering if there is a way to change the color of the panels of the xyplot (lattice package) from gray to white .. Because the printing of the xyplot's graph is not visible with the gray color ... I've seen the xyplot help but without any success Thanks

Re: [R] background color of xyplot

2005-10-09 Thread ronggui
see ?trellis.device trellis.device(color=F) Depth - equal.count(quakes$depth, number=8, overlap=.1) xyplot(lat ~ long | Depth, data = quakes) will get what you want. === 2005-10-09 22:32:10 您在来信中写道:=== Dear All, I am wondering if there is a way to change the

Re: [R] color for points

2005-10-09 Thread Vincent Goulet
Le 8 Octobre 2005 05:35, [EMAIL PROTECTED] a écrit : Sam R. Smith a écrit : Hi, I have the following code to randomly generate the points: csr -function(n=60){ x=runif(n) y=runif(n) f=cbind(x,y) } plot(csr()) I wonder how to code to make the first twenty points to be BLUE;

Re: [R] Glmm for multiple outcomes

2005-10-09 Thread Spencer Graves
Does the following help: n.subjects - 3 J - 4 K - 5 n.ijk - rep(2, each=n.subjects*J*K) x - rep(1:K, n.subjects, each=J) subj - factor(rep(1:n.subjects, each=K*J)) sa.subject - 1 sb.subject - 1 set.seed(2) a.subj - rep(sa.subject*rnorm(n.subjects), each=K*J) b.subj -

[R] Insert value from same column of another row (lag across observations)

2005-10-09 Thread David L. Van Brunt, Ph.D.
I know I've done this before, but it's been a while and I can't find quite what I need in the help files or archives. I have a text field in a very large data frame. I'd like to add a column that represents the value from an existing field, from the next record (the data are sorted). I'm trying

[R] enter a survey design in survey2.9

2005-10-09 Thread justin bem
Hi dears, I expect that Mr Thomas Lumley will read this message. I have data from a complexe stratified survey. The population is divide in 12 regions and a region consist to and urban area and rural one. there to region just with urbain area. stratification variable is a combinaison of

Re: [R] Error using a data frame as the start parameter in mle()

2005-10-09 Thread Spencer Graves
I will attempt a brief comment on this post, as I've seen no replies. It's difficult to comment on this, as you do not really provide enough information to permit someone like me to understand your problem. Only one portion of this problem is the fact that I can't find your

Re: [R] Matrix calculations in R--erroneous?

2005-10-09 Thread Thomas Lumley
On Fri, 7 Oct 2005, Peter Muhlberger wrote: The max function won't do the trick because I need the entire matrix. I could do one cell at a time, but this is part of a ML routine that needs to be evaluated hundreds of thousands of times, so I can't afford to slow it down that much. pmax,

[R] acf.plot() question

2005-10-09 Thread DeBarr, Dave
When I run the acf() function using the acf(ts.union(mdeaths, fdeaths)) example, the acf() function calls the acf.plot() function to generate this plot... http://members.cox.net/ddebarr/images/acf_example.png The plot in the lower right-hand corner is labeled fdeaths mdeaths, but the negative

[R] greek symbols using pch

2005-10-09 Thread FISCHER, Matthew
Hi R-users, In a plot, can I specify pch to be a greek symbol? (I looked at show.pch() in the Hmisc package but couldn't see the right symbols in there). If not, I guess I can get around this using text(x,y,expression()). cheers!, Matt. Dr Matt Fischer Postdoctoral Fellow - IPILPS ANSTO

[R] possible bug in image() ??

2005-10-09 Thread Gareth Davies
Hi everyone. The function image() seems not to be correctly plotting some matrices that I give it. (I’m using R 2.1.1) The following code creates a matrix (denoted x) with 1500 rows and 3 columns, with all entries 0 or 1, and then plots the image of this matrix.

Re: [R] greek symbols using pch

2005-10-09 Thread Marc Schwartz
On Mon, 2005-10-10 at 12:02 +1000, FISCHER, Matthew wrote: Hi R-users, In a plot, can I specify pch to be a greek symbol? (I looked at show.pch() in the Hmisc package but couldn't see the right symbols in there). If not, I guess I can get around this using text(x,y,expression()).

[R] plot

2005-10-09 Thread Sam R. Smith
After I made a new plot, the old plot can not be found. How can I check all the plots I have made? - [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list

Re: [R] plot

2005-10-09 Thread Murray Pung
Select History Recording. You can see previous plots using 'page up'. Murray -Original Message- From: Sam R. Smith [mailto:[EMAIL PROTECTED] Sent: Monday, 10 October 2005 1:27 PM To: r-help@stat.math.ethz.ch Subject: [R] plot After I made a new plot, the old plot can not be found.

[R] sqlFetch on MySQL-DB

2005-10-09 Thread Bernd Weiss
Dear all, I successfully set up a local MySQL-database. Connecting via RODBC is not problem, the same in fetching 3 of 4 tables. But trying to connect to table 4 fails. author-sqlFetch(test,author) Error in fromchar(unclass(x)) : character string is not in a standard unambiguous format In

[R] line

2005-10-09 Thread Sam R. Smith
There are four points with coordinates: 2,3;4,9;1,6;3,10. How to use Python to draw one perpendicular bisector between (2,3) and (4,9); the other perpendicular bisector between (1,6)ºÍ(3,10); then, makes the output like: l1 a b c l2 a b c (Note: l indicates the perpendicular bisector with equation

Re: [R] line

2005-10-09 Thread Sam R. Smith
Sorry for the typo, ask for R code. Sam R. Smith [EMAIL PROTECTED] wrote:There are four points with coordinates: 2,3;4,9;1,6;3,10. How to use Python to draw one perpendicular bisector between (2,3) and (4,9); the other perpendicular bisector between (1,6)ºÍ(3,10); then, makes the output like: l1