Re: [R] R kicking us out

2006-06-14 Thread J Dougherty
On Tuesday 13 June 2006 13:00, Erin Hodgess wrote: Dear R People: I am using R for teaching purposes in a large classroom. Each computer has its own copy of R. However, every once in a while, about half of us will get thrown out of R, for no apparent reason. By the way, it has happened

[R] Decimal series how to make.........

2006-06-14 Thread anil kumar rohilla
Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by default increment 1 it is taking ,so what to do ,, i want to use this

Re: [R] Decimal series how to make.........

2006-06-14 Thread Niels Vestergaard Jensen
On 14 Jun 2006, anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by default increment 1 it is

Re: [R] Decimal series how to make.........

2006-06-14 Thread Simon Blomberg
?seq anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by default increment 1 it is taking

[R] A whine and a request

2006-06-14 Thread John Vokey
guRus and useRs, As I instruct my students: With R what is difficult in anything else, is easy, usually one line of code; but, what is easy in anything else, is *^%$%#$... (translation: next to impossible) in R. I just ran into such a case that has, to put it mildly, driven me to use

Re: [R] missing value where TRUE/FALSE needed

2006-06-14 Thread Petr Pikal
Hi as nobody has any of your variables and can not reproduce your code you has to track your problems yourself. R is kindly provided you with hint for it. a-1 b-2 value-2 if(value=avalue=b) print(right) else print(wrong) [1] right b-NA if(value=avalue=b) print(right) else print(wrong) Error in

Re: [R] 2 Courses Near You - (1) Introduction to R/S+ programming: Microarrays Analysis and Bioconductor, (2) R/Splus Fundamentals and Programming Techniques

2006-06-14 Thread Jari Oksanen
On Tue, 2006-06-13 at 21:34 +0200, Uwe Ligges wrote: ... and again I wonder which courses are near. This leads at once to the question: which metric is in use?. Possibly this: ### Great Circle distances ### Use different sign to N and S, and to E and W ### (does not matter which sign) ### Lat

[R] R ``literal'' comand

2006-06-14 Thread John Vokey
I know I am luddite when it comes to list-based languages, such as R. But, even these beasts must occasionally want to access objects at a literal level. For example, to a naive twit like me, x--print (y) should deposit in x a literal print out of y; that is, x should contain the

[R] could someone tell me how to implement a multiple comparison test for proportions in a 2xc crosstabulation

2006-06-14 Thread xingwang ye
Dear all, I wanna to do multiple comparison test for proportions (multiple chi squre ?), could someone tell me how in R, thank you! __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide!

[R] matrix log

2006-06-14 Thread Brandon . J . Whitcher
Dear R users, Has anyone implemented a matrix log function in R similar to the function logm() in Matlab? I did a quick R site search and browsed the contributed packages to no avail. The octave function is far too simplistic and fails for the Matlab test matrix. Ideally, the code of Cheng,

Re: [R] R ``literal'' comand

2006-06-14 Thread Bjørn-Helge Mevik
capture.output(...) If you want a single string, with newlines: paste(capture.output(...), collapse = \n) -- Bjørn-Helge Mevik __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide!

[R] set.seed

2006-06-14 Thread Xiaohua Dai
Hi R users, Sorry for a simple question: I found different people use different i in set.seed(i), are there any rules to choose an i or one can choose as he likes? Thanks Xiaohua __ R-help@stat.math.ethz.ch mailing list

Re: [R] Decimal series how to make.........

2006-06-14 Thread Ted Harding
On 14-Jun-06 anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by default increment 1 it is

Re: [R] A whine and a request

2006-06-14 Thread Liaw, Andy
I'm not sure if I understand your problem exactly, so I'm taking a wild guess: When you coerce a 2-d table object to data frame, what you get are three columns: the two class variables and the frequencies. If so, this might help: x - sample(1:2, 20, replace=TRUE) y - sample(1:3, 20,

Re: [R] could someone tell me how to implement a multiple comparison test for proportions in a 2xc crosstabulation

2006-06-14 Thread ronggui
?p.adjust It's the function used to Adjust P-values for Multiple Comparisons. 2006/6/14, xingwang ye [EMAIL PROTECTED]: Dear all, I wanna to do multiple comparison test for proportions (multiple chi squre ?), could someone tell me how in R, thank you!

Re: [R] Cramer-von Mises normality test

2006-06-14 Thread Raymond Wan
Hi Robert, On Tue, 13 Jun 2006, Robert Powell wrote: I've been running some normality tests using the nortest package. For some of my datasets the Cramer-von Mises normality test generates an extremely high probability (e.g., 1.637e+31) and indicates normality when the other tests do not. Is

Re: [R] set.seed

2006-06-14 Thread ronggui
set.seed is used to set the random number seed. When we use functions ,say runif, to generate random number ,we almost get different set of random number. runif(5) [1] 0.2096388 0.3427873 0.5455948 0.7694844 0.4287647 runif(5) [1] 0.6864617 0.5218690 0.7965364 0.9030520 0.4324572 But in some

Re: [R] could someone tell me how to implement a multiple comparison test for proportions in a 2xc crosstabulation

2006-06-14 Thread Xiaoting Hua
Maybe you want the package multcomp. On 6/14/06, xingwang ye [EMAIL PROTECTED] wrote: Dear all, I wanna to do multiple comparison test for proportions (multiple chi squre ?), could someone tell me how in R, thank you! __ R-help@stat.math.ethz.ch

Re: [R] set.seed

2006-06-14 Thread Barry Rowlingson
ronggui wrote: set.seed is used to set the random number seed. When we use functions ,say runif, to generate random number ,we almost get different set of random number. As for what the i in set.seed(i) should be,I don't think it is a serious matter. The help for set.seed tells you all

[R] how to make a series with decimal increment

2006-06-14 Thread anil kumar rohilla
Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by default increment 1 it is taking ,so what to do ,, i want to

[R] write data from function into external table

2006-06-14 Thread Sebastian Leuzinger
Dear list, My apologies if a solution / explanation to this already exists on the list, but it is difficult to assign it to a certain keyword. test-c(1:3) testfct - function(x) {test[1]-100} test [1] 1 2 3 testfct(1) [1] 1 2 3 Basically, I would like to write data into an external table that

[R] R internal clock time discrepancy

2006-06-14 Thread toby marthews
Dear R: I'm trying to map some time series data on to dates and because I'm using R's strptime' facility I get an hour's break in my time series: my readings for between 1am and 2am on 27th March 2005 won't map onto anything (I'm using a data logger to record temperature and other things in a

Re: [R] write data from function into external table

2006-06-14 Thread Dimitris Rizopoulos
maybe you're looking for something like, test - 1:3 testfct - function(x){ x[1] - 100 x } test testfct(1) testfct(test) I hope it helps. Best, Dimitris Dimitris Rizopoulos Ph.D. Student Biostatistical Centre School of Public Health Catholic University of Leuven

Re: [R] write data from function into external table

2006-06-14 Thread Adaikalavan Ramasamy
What is your desired output ? This will clarify the problem greatly. Perhaps, this might be of some use : f - function(v, pos, val=100){ v[pos] - val; return(v) } test - 1:3 test - f(test, 1) test [1] 100 2 3 Regards, ADai On Wed, 2006-06-14 at 12:41 +0200, Sebastian Leuzinger

[R] Estimate region of highest probabilty density

2006-06-14 Thread Ort Christoph
Estimate region of highest probabilty density Dear R-community I have data consisting of x and y. To each pair (x,y) a z value (weight) is assigned. With kde2d I can estimate the densities on a regular grid and based on this make a contour plot (not considering the z-values). According to an

Re: [R] Decimal series how to make.........

2006-06-14 Thread Gabor Grothendieck
On 6/14/06, Ted Harding [EMAIL PROTECTED] wrote: On 14-Jun-06 anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving

Re: [R] write data from function into external table

2006-06-14 Thread Gabor Grothendieck
Here are two alternatives. See ?- testfct1 - function() test[1] - 100 # following one can be written more compactly as # testfct2 - function(test) replace(test, 1, 100) testfct2 - function(test) { test[1] - 100; test } # test test - 1:3; testfct1(); test test - 1:3; test - testfct2(test);

Re: [R] write data from function into external table

2006-06-14 Thread Sebastian Leuzinger
Thanks for the hints, they are useful to me. However, I still do not understand why my approach fails. In a user defined function, R does not seem to want to write into an object defined outside this function. (see my first example below). I guess there is some logic behind this. On Wednesday

[R] lmer binomial model overestimating data?

2006-06-14 Thread Martin Henry H. Stevens
Hi folks, Warning: I don't know if the result I am getting makes sense, so this may be a statistics question. The fitted values from my binomial lmer mixed model seem to consistently overestimate the cell means, and I don't know why. I assume I am doing something stupid. Below I include

Re: [R] write data from function into external table

2006-06-14 Thread Niels Vestergaard Jensen
On Wed, 14 Jun 2006, Sebastian Leuzinger wrote: Thanks for the hints, they are useful to me. However, I still do not understand why my approach fails. In a user defined function, R does not seem to want to write into an object defined outside this function. (see my first example below). I

Re: [R] write data from function into external table

2006-06-14 Thread Gabor Grothendieck
If functions don't modify their environment then its generally easier to debug programs so it encourarges better programming. On 6/14/06, Sebastian Leuzinger [EMAIL PROTECTED] wrote: Thanks for the hints, they are useful to me. However, I still do not understand why my approach fails. In a user

[R] number of iteration s exceeded maximum of 50

2006-06-14 Thread Leaf Sun
Hi all, I found r-site-research not work for me these days. When I was doing nls( ) , there was an error number of iterations exceeded maximum of 50. I set number in nls.control which is supposed to control the number of iterations but it didn't work well. Could anybody with this experience

Re: [R] Decimal series how to make.........

2006-06-14 Thread Ted Harding
On 14-Jun-06 Gabor Grothendieck wrote: On 6/14/06, Ted Harding [EMAIL PROTECTED] wrote: On 14-Jun-06 anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i

[R] fclustIndex(package e1071) error: LaPack Routine dgesv

2006-06-14 Thread Christopher Bail
Dear colleagues: Despite my best efforts, I have not been able to understand/overcome an error message I received while running the fclustIndex command in package e1071, which produces validity measures for the fuzzy c-means clustering algorithm. I am relatively new to R-- and still depend

[R] lmer and mixed effects logistic regression

2006-06-14 Thread Rick Bilonick
I'm using FC4 and R 2.3.1 to fit a mixed effects logistic regression. The response is 0/1 and both the response and the age are the same for each pair of observations for each subject (some observations are not paired). For example: id response age 10 30 10 30 21 55 2

Re: [R] missing value where TRUE/FALSE needed

2006-06-14 Thread Peter Lauren
Hi Petr, You are correct. There was an NA in BinMatrix. I made the mistake of only looking at the earlier entries. My problem was in this loop for (i in 2:BinCnt) { BinMatrix[i,1]=BinMatrix[i-1,2] BinMatrix[i,2]=BinMatrix[i,2]+Increment } It should have been for (i in 2:BinCnt) {

[R] merge dataframes with conditions formulated as logical expressions

2006-06-14 Thread Wolfram Fischer
I have a data.frame df containing two variables: GRP: Factor VAL: num I have a data.frame dp containing: GRP: Factor MIN.VAL: num MAX.VAL: num VAL2: num with several rows per GRP where dp[i-1, MAX.VAL] dp[i, MIN.VAL] within the same GRP. I want to create df[i, VAL2] -

Re: [R] data set size question

2006-06-14 Thread Greg Snow
If you need to analyze something bigger than memory can hold, one option is the biglm package which will fit linear regression models (and a lot of different analyses can be restructured as linear regression models) on blocks of data so that the entire dataset is not in memory all at the same

[R] positioning of separate y-axis labels in xyplot

2006-06-14 Thread Benjamin Tyner
I like the functionality provided by outer=TRUE, but when it comes time to place separate xlabs or ylabs, I always end up 'eyeballing' it on a case-by-case basis. For example, ##begin example require(lattice) cars.lo - loess(dist ~ speed, cars)

Re: [R] Decimal series how to make.........

2006-06-14 Thread Gabor Grothendieck
I agree although if you use this construct a lot then you will likely want to adopt the easier-to-write 0:10/10 style as an idiom. I find this is particularly the case with rq from the quantreg package where its convenient to use it in specifying the tau= arg: library(quantreg) data(engel) rq(y

[R] storing/retrieving simulation data

2006-06-14 Thread Jeff Miller
Hi all, Would someone please provide efficient code for sending Monte Carlo simulation results and/or graphs run by run to an output file. This is followed by pulling the file back in for subsequent analyses. This is probably topic-specific, so here is a basic example. Suppose I want to

[R] data managment

2006-06-14 Thread yohannes alazar
First I would really like to thank the mailing list for help I got in the past, as a new to R I am really needing some support on hoe to code the following problem. I am trying to sort some data I have in a big file. The file has 4 columns and 19000 rows. An example of it looks like this:- G

Re: [R] positioning of separate y-axis labels in xyplot

2006-06-14 Thread Deepayan Sarkar
On 6/14/06, Benjamin Tyner [EMAIL PROTECTED] wrote: I like the functionality provided by outer=TRUE, but when it comes time to place separate xlabs or ylabs, I always end up 'eyeballing' it on a case-by-case basis. For example, ##begin example require(lattice) cars.lo - loess(dist ~ speed,

Re: [R] merge dataframes with conditions formulated as logical expressions

2006-06-14 Thread Adaikalavan Ramasamy
You have discontinuity between your MIN.VAL and MAX.VAL for a given group. If this is true in practise, then you may want to check and report when VAL is in the discontinuous region. Here is my solution that ignores that (and only uses MIN.VAL and completely disrespecting MAX.VAL). Not very

[R] appending

2006-06-14 Thread Afshartous, David
All, In the function below I have 24 individuals and 6 calculations per individual. The 6 calculations are collected each time in a 1:24 loop when calculating delta. I'd like to collect all 144 = 24*6 calculations in one vector (delta.patient.comb). The function works as is via indexing, but is

Re: [R] how to make a series with decimal increment

2006-06-14 Thread Gavin Simpson
On Tue, 2006-06-13 at 05:24 +, anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 i tryed this statement s-0:0.1:1 but this giving an error megssage. but by

[R] FireFox Upgrade Breaks R(?)

2006-06-14 Thread Tim Evans
Just upgraded Firefox to the current (1.5.0.4) release on a RedHat 7.3 system. R now whines that /usr/lib/i386/libjavaplugin_nscp.so doesn't exist. Well, no, the referenced i386 subdir (and plugin) exists in the JRE directory tree, not at the top level of /usr/lib. And, if I restore the

Re: [R] appending

2006-06-14 Thread Martin Henry H. Stevens
Hi David, It would be helpful if you supply a little data, upon which this would operate. Hank On Jun 14, 2006, at 12:31 PM, Afshartous, David wrote: All, In the function below I have 24 individuals and 6 calculations per individual. The 6 calculations are collected each time in a 1:24

[R] graph

2006-06-14 Thread Ahmed Elhabti
Bonjour, Je veux savoir comment je peux avoir avec R deux graphiques en un seul graphique? Exemple Hi, I want to know how I can have with R two graphs in only one graph? Example x-seq(0,4,0.1) plot(x,dnorm(x),type=l) plot(x,dgamma(x,2,0.5),typ=p) Thanks

Re: [R] graph

2006-06-14 Thread Gabor Csardi
On Wed, Jun 14, 2006 at 07:23:53PM +0200, Ahmed Elhabti wrote: [...] Hi, I want to know how I can have with R two graphs in only one graph? Example x-seq(0,4,0.1) plot(x,dnorm(x),type=l) plot(x,dgamma(x,2,0.5),typ=p) in the last line, use 'points' instead of 'plot':

[R] A question about stepwise procedures: step function

2006-06-14 Thread Li, Jia
Dear all, I tried to use step function to do model selection, but I got an error massage. What I don't understand is that data as data.frame worked well for my other programs, how come I cannot make it run this time. Could you please tell me how I can fix it?

Re: [R] appending

2006-06-14 Thread Afshartous, David
Hank, Attached is the dataframe that can be supplied for the argument comp.CAND.frm. The argument for comp.LIS.frm can be deleted since it currently isn't used. The other arguments can be set as: delta.0.Y.0 = 50 gamma = 40. cheers, dave -Original Message- From: Martin Henry H.

Re: [R] data managment

2006-06-14 Thread jim holtman
This 'applies' a function to each row to reverse columns if necessary: x V1V2 V3V4 1 G 0.892 A 0.108 2 G 0.883 T 0.117 3 T 0.500 C 0.500 4 A 0.617 G 0.383 5 G 0.925 A 0.075 6 A 0.967 G 0.033 7 C 0.883 T 0.117 8 C 0.633 T 0.367 9 G 0.950 A 0.050 10 C 0.742

Re: [R] how to make a series with decimal increment

2006-06-14 Thread Michael Prager
Gavin Simpson wrote on 6/14/2006 12:44 PM: On Tue, 2006-06-13 at 05:24 +, anil kumar rohilla wrote: Hi List, I am new to this Rsoftware, i want to make a sereis for example which is having values like this, s- 0,0.1,0.2,0.3,0.4,1 [...] Hi Anil, see ?seq for the

Re: [R] bubbleplot for matrix

2006-06-14 Thread bogdan romocea
Here's an example. By the way, I find that it's more convenient (where applicable) to keep the data in 3 vectors/factors rather than one matrix/data frame. a - matrix(sample(1:5,100,replace=TRUE),nrow=10,dimnames=list(1:10,5*1:10)) x - y - z - vector() for (i in 1:nrow(a)) { x -

[R] Saving R graphics with version 2.3.1

2006-06-14 Thread ilka
HI ! I´ve installed the latest R version (2.3.1) and I´ve had problems to save my graphics as JPEG, PNG and the others available formats. R saves the file with no extension. Then, I have to open this file using an image visualizer and save it as PNG, for instance. Previous R versions work

Re: [R] Multiple lag.plots per page

2006-06-14 Thread Gad Abraham
Prof Brian Ripley wrote: On Wed, 14 Jun 2006, Gad Abraham wrote: Prof Brian Ripley wrote: On Tue, 13 Jun 2006, Gad Abraham wrote: Prof Brian Ripley wrote: On Tue, 13 Jun 2006, Gad Abraham wrote: Hi, I'm trying to plot several lag.plots on a page, however the second plot replaces the

[R] How to change the margin widths in png-plots?

2006-06-14 Thread kone
Hello, I have tried to change the margin widths so that mtext (here sd of consecutive pc intervals, look at the picture) and plot(...,xlab=bar) fits to the picture. Here is an example: http://users.utu.fi/attenka/margins.png This doesn't help: par(mar=c(5.1, 7.1, 4.1, 2.1)) And here are

[R] How to change the margin widths in png-plots?

2006-06-14 Thread Atte Tenkanen
Hello, I have tried to change the margin widths so that mtext (here sd of consecutive pc intervals, look at the picture) and plot(...,xlab=bar) fits to the picture. Here is an example: http://users.utu.fi/attenka/margins.png This doesn't help: par(mar=c(5.1, 7.1, 4.1, 2.1)) And here are

Re: [R] Garch Warning

2006-06-14 Thread Spencer Graves
Your example is not reproducible. Have you tried walking through the code line by line after debug(garch)? After you've tried that, if you'd still like help from this listserve, please submit a simple, self-contained / reproducible example, as suggested the posting guide!

Re: [R] Garch Warning

2006-06-14 Thread Arun Kumar Saha
Dear Spencer, Can you be more clear on your suggestion? On 6/15/06, Spencer Graves [EMAIL PROTECTED] wrote: Your example is not reproducible. Have you tried walking through the code line by line after debug(garch)? After you've tried that, if you'd still like help from this

[R] MDS with missing data?

2006-06-14 Thread context grey
Hello I will be applying MDS (actually Isomap) to make a psychological concept map of the similarities between N concepts. I would like to scale to a large number of concepts, however, the resulting N*(N-1) pairwise similarities is prohibitive for a user survey. I'm thinking of giving people

Re: [R] MDS with missing data?

2006-06-14 Thread Jari Oksanen
Dear Context Grey, On 15 Jun 2006, at 6:42, context grey wrote: I will be applying MDS (actually Isomap) to make a psychological concept map of the similarities between N concepts. So actually, how do you do isomap? RSiteSearch gave me one hit of isomap. I only ask, because I've

Re: [R] Saving R graphics with version 2.3.1

2006-06-14 Thread Ritwik Sinha
Hi, Have a jpeg() your plot function dev.off() That will direct your graphs to a file called Rplots.jpg. Look for function jpeg and png. On 6/14/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: HI ! I´ve installed the latest R version (2.3.1) and I´ve had problems to save my graphics as

Re: [R] merge dataframes with conditions formulated as logical expressions

2006-06-14 Thread Wolfram Fischer
--- Reply to: --- Date:14.06.06 16:17 (+) From:Adaikalavan Ramasamy [EMAIL PROTECTED] Subject: Re: [R] merge dataframes with conditions formulated as logical expressions You have discontinuity between your MIN.VAL and MAX.VAL for a given group. If this is true in practise, then you