[R] Conjoint Analysis in R??

2007-12-06 Thread faisal afzal siddiqui
Pls advise how I can use R in conjoint analysis?? regds Faisal Afzal Siddiqui Karachi, Pakistan Looking for last minute shopping deals? __

Re: [R] how to interpolate a plot with a logistic curve

2007-12-06 Thread Christian Ritz
Dear Simone, you can use the package 'drc' to fit a logistic model, that is a non-linear regression model based on the equation c+(d-c)/(1+exp(b(x-e))), to your data (below named 'simone'): ## Fitting a 4-parameter logistic model (also called Boltzmann model) simone.m1 - drm(size~x,

Re: [R] correlation coefficient from qq plot

2007-12-06 Thread Domenico Vistocco
You could use the qqnorm function to obtain the correlation, as: qqp=qqnorm(rstudent(regrname)) cor(qqp$x,qqp$y) If you do not want see the plot (as the qq.plot is richer): qqp=qqnorm(rstudent(regrname), plot.it=F) domenico vistocco Tom Fitzhugh wrote: Hi, I am trying to figure out

[R] R CMD Build feature searches or requests

2007-12-06 Thread Johannes Graumann
Hello, I'm missing two features in R CMD build: 1) Easy building of Windows/zip packaged package version alongside the *nix-style *.tar.gz. Right now I'm doing a scripted version of R CMD build PACKAGE R CMD INSTALL PACKAGE mkdir tmp cp -r

Re: [R] Using panel.densityplot with stripplot

2007-12-06 Thread Christopher Oezbek
Hi Deepayan! thank you! panel.violin with the following modification works as I want: grid.polyline(x = dx.list[[i]], y = dy.list[[i]], ... instead of grid.polygon(x = c(dx.list[[i]], rev(dx.list[[i]])), y = c(dy.list[[i]], -rev(dy.list[[i]])), ... From examples I would

Re: [R] Using expression in Hmisc Key()

2007-12-06 Thread Michael Kubovy
Hi Dieter, I actually solved *my* problem: Key(x = 0.667, y = 0.833, lev = c(expression(italic(b)), expression(italic(c)), expression(italic(d))), other = list(title = expression(italic(v)), cex.title = 1)) I was able to figure this out only by looking at the code for Key(), because

[R] colour coded points in biplot

2007-12-06 Thread Petr PIKAL
Dear all I tried to make a biplot with color coded labels but I was not successful. Searching archives I found that it is probably not so simple. I found http://tolstoy.newcastle.edu.au/R/help/05/01/10661.html which recommends eqscplot eqscplot(fit$score[,1], fit$score[,2], pch = 20,

Re: [R] Segmented regression

2007-12-06 Thread vito muggeo
Dear Brendan, I am not sure to understand your code.. It seems to me that your are interested in fitting a one-breakpoint segmented relationship in each level of your grouping variable If this is the case, the correct code is below. In order to fit a segmented relationship in each group you

[R] Building package - tab delimited example data issue

2007-12-06 Thread Johannes Graumann
Hello, I'm trying to integrate example data in the shape of a tab delimited ASCII file into my package and therefore dropped it into the data subdirectory. The build works out just fine, but when I attempt to install I get: ** building package indices ... Error in scan(file, what, nmax, sep,

Re: [R] Conjoint Analysis in R??

2007-12-06 Thread Domenico Vistocco
http://tolstoy.newcastle.edu.au/R/help/05/06/6104.html http://tolstoy.newcastle.edu.au/R/help/05/06/6103.html domenico faisal afzal siddiqui wrote: Pls advise how I can use R in conjoint analysis?? regds Faisal Afzal Siddiqui Karachi, Pakistan

Re: [R] Conjoint Analysis in R??

2007-12-06 Thread paulandpen
Faisal, can you elaborate further on your conjoint design there is bayesm which offers a hierarchical bayes approach to analysing choice data MLogit available through zelig (see below) http://gking.harvard.edu/zelig/docs/index.html MNP as a standalone package for the probit model thanks

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Peter Dalgaard
Johannes Graumann wrote: Hello, I'm trying to integrate example data in the shape of a tab delimited ASCII file into my package and therefore dropped it into the data subdirectory. The build works out just fine, but when I attempt to install I get: ** building package indices ... Error in

Re: [R] R function for percentrank

2007-12-06 Thread Martin Maechler
MS == Marc Schwartz [EMAIL PROTECTED] on Wed, 05 Dec 2007 12:43:50 -0600 writes: [] MS Martin, MS Thanks for the corrections. In hindsight, now seeing the intended use of MS ecdf() in the fashion you describe above, it is now clear that my MS approach in

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Berwin A Turlach
G'day Peter, On Thu, 06 Dec 2007 11:52:46 +0100 Peter Dalgaard [EMAIL PROTECTED] wrote: If you had looked at help(data), you would have found a list of which file formats it supports and how they are read. Hint: TAB-delimited files are not among them. [...] On the other hand, Writing R

Re: [R] colour coded points in biplot

2007-12-06 Thread Domenico Vistocco
If you are using correspondence analysis you could see the plot.ca function in the ca library. Petr PIKAL wrote: Dear all I tried to make a biplot with color coded labels but I was not successful. Searching archives I found that it is probably not so simple. I found

Re: [R] how to interpolate a plot with a logistic curve

2007-12-06 Thread Simone Gabbriellini
Dear Christian, it works great, and it is simple to understand, thank you very much. just a detail, is it possible to plot just the fitted curve and not the data? it's because I would like to have data in black and the fitted curve in red.. I don't know how to pick up the single parts, if

Re: [R] how to interpolate a plot with a logistic curve

2007-12-06 Thread Simone Gabbriellini
Dear Christian, it works great, and it is simple to understand, thank you very much. just a detail, is it possible to plot just the fitted curve and not the data? it's because I would like to have data in black and the fitted curve in red.. I don't know how to pick up the single parts, if

[R] $ operator is invalid for atomic vectors, returning NULL - what is the right thing to do then?

2007-12-06 Thread Søren Højsgaard
Dear all, Starting from a recent version of R, the $ became unusable on atomic vectors, e.g. x - c(a=1,b=2) x$a NULL Warning message: In x$a : $ operator is invalid for atomic vectors, returning NULL I can of course do x['a'] - but that requires more typing (5 characters rather than 2).

[R] Nine questions about methods and generics

2007-12-06 Thread Michael Dewey
I have a series of question about methods and generics. The questions are interspersed in some text which explains what I want to do, how it works now and why I do not understand well why it works. Questions are written Q1 and so on up to Q9 and always start a new line. The concrete problem is

Re: [R] $ operator is invalid for atomic vectors, returning NULL - what is the right thing to do then?

2007-12-06 Thread Prof Brian Ripley
On Thu, 6 Dec 2007, Søren Højsgaard wrote: Dear all, Starting from a recent version of R, From R 2.5.0, not so recent. the $ became unusable on atomic vectors, e.g. x - c(a=1,b=2) x$a NULL Warning message: In x$a : $ operator is invalid for atomic vectors, returning NULL I can of course

Re: [R] R function for percentrank

2007-12-06 Thread Gabor Grothendieck
On Dec 6, 2007 6:11 AM, Martin Maechler [EMAIL PROTECTED] wrote: MS == Marc Schwartz [EMAIL PROTECTED] on Wed, 05 Dec 2007 12:43:50 -0600 writes: [] MS Martin, MS Thanks for the corrections. In hindsight, now seeing the intended use of MS ecdf() in the fashion

Re: [R] $ operator is invalid for atomic vectors, returning NULL

2007-12-06 Thread Ted Harding
On 06-Dec-07 12:04:56, Søren Højsgaard wrote: Dear all, Starting from a recent version of R, the $ became unusable on atomic vectors, e.g. x - c(a=1,b=2) x$a NULL Warning message: In x$a : $ operator is invalid for atomic vectors, returning NULL I can of course do x['a'] - but that

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Peter Dalgaard
Berwin A Turlach wrote: G'day Peter, On Thu, 06 Dec 2007 11:52:46 +0100 Peter Dalgaard [EMAIL PROTECTED] wrote: If you had looked at help(data), you would have found a list of which file formats it supports and how they are read. Hint: TAB-delimited files are not among them. [...]

[R] differences in using source() or console

2007-12-06 Thread vito muggeo
Dear all, Is there *any* reason explaining what I describe below? I have the following line myfun(x) If I type them directly in R (or copy/past), it works.. However if I type in R 2.6.1 source(code.R) ##code.R includes the above line Error in inherits(x, data.frame) : object d not found

[R] R2HTML how to pair graphic.png and table

2007-12-06 Thread Roberto Iacopetti
Dear list, i have this problem: how to pair a graphic.png and a table in R2HTML ? The better showing of a mutiple analysis is sometimes to mate graphic and table Can anyone help me in this task ?? In the example below graphisc and table are subsequent and not pair.. directory=getwd()

[R] 64-bit R question in Leopard

2007-12-06 Thread 정 태훈
Hi, All; I've compiled and installed successfully presumably 64-bit R on Leopard. But when I tried to run R, I got the following error: /usr/bin/R: line 179: /Library/Frameworks/R.framework/Resources/etc/ i386/ldpaths: No such file or directory Here is the configuration I used:

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Johannes Graumann
Johannes Graumann wrote: On Thursday 06 December 2007 11:52:46 Peter Dalgaard wrote: Johannes Graumann wrote: Hello, I'm trying to integrate example data in the shape of a tab delimited ASCII file into my package and therefore dropped it into the data subdirectory. The build works out

Re: [R] R2HTML how to pair graphic.png and table

2007-12-06 Thread Eric Lecoutre
Hi Roberto, here is a way that presumes you know some (basic) HTML tags: library(R2HTML) directory=getwd() myfile-file.path(directory,testHTML.html) HTMLoutput=file.path(directory,testHTML.html) graf=graf.png png(file.path(directory,graf)) plot(c(1:12)) dev.off() tab-as.matrix(c(1:12))

Re: [R] $ operator is invalid for atomic vectors, returning NULL - what is the right thing to do then?

2007-12-06 Thread Duncan Murdoch
On 12/6/2007 7:04 AM, Søren Højsgaard wrote: Dear all, Starting from a recent version of R, the $ became unusable on atomic vectors, e.g. x - c(a=1,b=2) x$a NULL Warning message: In x$a : $ operator is invalid for atomic vectors, returning NULL I can of course do x['a'] - but that

Re: [R] hclust in heatmap.2

2007-12-06 Thread James W. MacDonald
affy snp wrote: Dear list, I am using heatmap.2(x) to draw a heatmap. Ideally, I want to the matrix x clustered only by columns and keep the original order of rows unchanged. Is there a way to do that in heatmap.2()? Thanks a lot! Any suggestions will be appreciated! From the help

Re: [R] R2HTML how to pair graphic.png and table

2007-12-06 Thread Domenico Vistocco
You could use a table with one row and two columns: HTML(TABLETD,file=HTMLoutput) HTML(tab,file=HTMLoutput) HTML(/TDTD,file=HTMLoutput) HTMLInsertGraph(graf,file=HTMLoutput,caption=Esempio di grafico) HTML(/TD/TABLE,file=HTMLoutput) domenico PS: You could create a function if this is a common

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Peter Dalgaard
Johannes Graumann wrote: Johannes Graumann wrote: On Thursday 06 December 2007 11:52:46 Peter Dalgaard wrote: Johannes Graumann wrote: Hello, I'm trying to integrate example data in the shape of a tab delimited ASCII file into my package and therefore dropped it into the

Re: [R] Junk or not Junk ???

2007-12-06 Thread David Hewitt
Loren Engrav wrote: Thank you As per advice from several R users I have set r-project.org, stat.math.ethz.ch,fhcrc.org, stat.ethz.ch, math.ethz.ch, hypatia.math.ethz.ch all to be safe domains But still some R emails go to Junk and require to be found manually I have explored

[R] Vertical text in a plot

2007-12-06 Thread Marcin Kozak
Hi, Consider this simple plot: plot(1:25,runif(25,0,1),ylab=First Y-axis label,xaxt=n) I want to add an additional axis as axis(4,at=seq(0.2,1,.2), labels=1:5) I have no idea how to add now the title of the new axis as Second Y-axis label. I want this text to be vertically directed from

[R] 64-bit R compiling problem on Leopard

2007-12-06 Thread 정 태훈
Hi, All; I've compiled and installed successfully presumably 64-bit R on Leopard. But when I tried to run R, I got the following error: /usr/bin/R: line 179: /Library/Frameworks/R.framework/Resources/etc/ i386/ldpaths: No such file or directory Here is the configuration I used:

Re: [R] Building package - tab delimited example data issue

2007-12-06 Thread Johannes Graumann
Peter Dalgaard wrote: Answering to myself and staying with the same example: system.file(data/stroke.csv,package=ISwR) allows direct access to the example file (name). Yes, but... This works right until you turn on LazyData for your package, then you end up with only

Re: [R] R2HTML how to pair graphic.png and table

2007-12-06 Thread Roberto Iacopetti
Eric, your code work well for my need, i'm not skillful in html environment, but your functions in R2HTML give simple many output requirements thanks Roberto Eric Lecoutre wrote: Hi Roberto, here is a way that presumes you know some (basic) HTML tags: library(R2HTML)

[R] Frequency and Phase Spectrograms

2007-12-06 Thread Todd Remund
I know that there is a function, (spectro3D), that produces the Power Spectrogram. Are there R functions that produce the Frequency Spectrogram and the Phase Spectrogram? Thank you for your time. [[alternative HTML version deleted]] __

Re: [R] hclust in heatmap.2

2007-12-06 Thread affy snp
Thanks Ashoka! Allen On Dec 6, 2007 12:27 AM, Ashoka Polpitiya [EMAIL PROTECTED] wrote: Check the Rowv, Colv options to heatmap.2 data(mtcars) x - as.matrix(mtcars) heatmap.2(x, Rowv=FALSE, dendrogram=column) -Ashoka Scientist - Pacific Northwest National Lab On Dec 5, 2007

Re: [R] hclust in heatmap.2

2007-12-06 Thread affy snp
Thanks James! Allen On Dec 6, 2007 9:21 AM, James W. MacDonald [EMAIL PROTECTED] wrote: affy snp wrote: Dear list, I am using heatmap.2(x) to draw a heatmap. Ideally, I want to the matrix x clustered only by columns and keep the original order of rows unchanged. Is there a way to

Re: [R] Vertical text in a plot

2007-12-06 Thread Gabor Grothendieck
There is an example in the example section of library(zoo) ?plot.zoo starting at: ## plot with left and right axes On Dec 6, 2007 10:16 AM, Marcin Kozak [EMAIL PROTECTED] wrote: Hi, Consider this simple plot: plot(1:25,runif(25,0,1),ylab=First Y-axis label,xaxt=n) I want to add an

Re: [R] alternatives to latex() or xtable()

2007-12-06 Thread A Friedman
An alternative solution that allows you to break it down by categories is in the functions below. Comments/suggestions welcome and encouraged. Note that much thanks is due to those who responded to an earlier post of mine on a similar topic. To use (assuming you have a data.frame falled

Re: [R] Sweave problem in Windows

2007-12-06 Thread MikeHA
huang min wrote: Hi, I have searched the lists but still can not solve the problem. I am using a windows machine. After I sweave some Rnw file, I got a tex file. However, the tex file can not be compiled. I know the problem is in the line

[R] Any package for deconvolution?

2007-12-06 Thread Chen, Gang (NIH/NIMH) [C]
I want to run deconvolution of a time series by an impulse or point-spread function through Wiener filter, regularized filter, Lucy-Richardson method, or any other approaches. I searched the CRAN website and the mailing list archive, but could not find any package for such a deconvolution

[R] R on a multi core unix box

2007-12-06 Thread Saeed Abu Nimeh
Hi, I installed the snow package on a unix box that has multiple cores. To be able to exploit the multiple cores (on one pc) do I still need to install the rmpi package (or rpvm). Another question, if i run a bayesian simulation on the multiple core after setting them up correctly (using snow),

Re: [R] Any package for deconvolution?

2007-12-06 Thread Richard . Cotton
The RTisean package has wiener filter functions (wiener1 and wiener2). Regards, Richie. Mathematical Sciences Unit HSL Chen, Gang (NIH/NIMH) [C] [EMAIL PROTECTED] Sent by: [EMAIL PROTECTED] 06/12/2007 16:20 To r-help@r-project.org cc Subject [R] Any package for deconvolution? I want

Re: [R] creating conditional means

2007-12-06 Thread Sherri Heck
hi gabor, i was able to get your suggestion to work. i have been going through the R help tools to figure out what each step actually does because i have something similar but hours 2,5,8,11,14,17 and 20 are missing. i haven't had any luck. each mean value that is calculated is the same.

Re: [R] Using panel.densityplot with stripplot

2007-12-06 Thread Deepayan Sarkar
On 12/6/07, Christopher Oezbek [EMAIL PROTECTED] wrote: But is there a technical reason for making this distinction? It seemed to me that most panel functions can deal with x and y parameters and that panel.densityplot could make use of the same mechanisms as panel.violin to subdivide based

[R] Help rewriting looping structure?

2007-12-06 Thread TLowe
Hey Folks, Could somebody help me rewrite the following code? I am looping through all records across 5 fields to calculate the cumulative percentage of each record (relative to each individual field). Is there a way to rewrite it so I don't have to loop through each individual record? #

Re: [R] creating conditional means

2007-12-06 Thread Gabor Grothendieck
The error message says you have duplicate row names and that is not allowed. Make sure you have the same number of elements on each line of data as in the header. If you have one more on each line than on the header then the first data item on each line will be regarded as the row name. See

Re: [R] Bootstrap Correlation Coefficient with Moving Block Bootstrap

2007-12-06 Thread Tim Hesterberg
It sounds like you should sample x and y together using the block bootstrap. If you have the usual situation, x and y in columns and observations in rows, then sample blocks of rows. Even though observations in y are independent, you would take advantage of that only for bootstrapping statistics

Re: [R] coxme frailty model standard errors?

2007-12-06 Thread Terry Therneau
--- begin included message I am running R 2.6.1 on windows xp I am trying to fit a cox proportional hazard model with a shared Gaussian frailty term using coxme My model is specified as: nofit1-coxme(Surv(Age,cen1new)~ Sex+bo2+bo3,random=~1|isl,data=mydat) With x1-x3 being dummy variables, and

[R] using eval(parse(text)) , gsub(pattern, replacement, x) , to process code within a loop/custom function

2007-12-06 Thread Thomas Pujol
R-help users, Thanks in advance for any assistance ... I truly appreciate your expertise. I searched help and could not figure this out, and think you can probably offer some helpful tips. I apologize if I missed something, which I'm sure I probably did. I have data for many samples.

Re: [R] Using expression in Hmisc Key()

2007-12-06 Thread Greg Snow
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Michael Kubovy Sent: Thursday, December 06, 2007 2:12 AM To: Dieter Menne Cc: [EMAIL PROTECTED] Subject: Re: [R] Using expression in Hmisc Key() [snip] This is one of the cases where I wish there

Re: [R] Any package for deconvolution?

2007-12-06 Thread Chen, Gang (NIH/NIMH) [C]
Thanks a lot for the quick pointer, Richie. I will take a close look of the RTisean package. Gang From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thu 12/6/2007 11:46 AM To: Chen, Gang (NIH/NIMH) [C] Cc: r-help@r-project.org Subject: Re: [R] Any package

Re: [R] logistic regression using glm,which y is set to be 1

2007-12-06 Thread Marc Schwartz
On Wed, 2007-12-05 at 22:33 -0800, Bin Yue wrote: Dear all: By comparing glmresult$y and model.response(model.frame(glmresult)), I have found out which one is set to be TRUE and which FALSE.But it seems that to fit a logistic regression , logit (or logistic) transformation has to be

Re: [R] Help rewriting looping structure?

2007-12-06 Thread Erik Iverson
How about this example? ## sample data frame with two columns df - data.frame(x = abs(rnorm(20)), y=abs(rnorm(20,2))) ## create new variables in df with an lapply call df[c(cpctx,cptcty)] - lapply(df, function(x) cumsum(x)/sum(x)) A possible improvement would be to construct the new column

Re: [R] Help rewriting looping structure?

2007-12-06 Thread jim holtman
Is this basically what you want to do? (Please include commented, minimal, self-contained, reproducible code so we don't have to guess at what you want) x - data.frame(a=runif(10), b=runif(10)) # do for one column cumsum(x$a)/sum(x$a) [1] 0.05892073 0.08129611 0.11067218 0.28640268 0.28969826

Re: [R] Help rewriting looping structure?

2007-12-06 Thread TLowe
Thank you all. That's exactly what I was looking for. TLowe wrote: Hey Folks, Could somebody help me rewrite the following code? I am looping through all records across 5 fields to calculate the cumulative percentage of each record (relative to each individual field). Is there a

[R] a question on stepAIC

2007-12-06 Thread Minya Pu
Hi, I am trying to use stepAIC to do forward stepwise selection for a logistic model. I did hi - glm(melanoma ~ ., family = binomial, data=data) lo - glm(melanoma ~ 1, family = binomial, data=data) stepAIC(lo, scope=list(upper = hi , lower = lo), direction = forward ) But the full model

Re: [R] Displaying numerics to full double precision

2007-12-06 Thread Jeff Delmerico
Thanks Ben, that fixed the display within R. However, even after changing the display settings, the matrix elements still appear to be exported in single precision. The matrix object is being passed into my C routines as an SEXP Numeric type, and somewhere along the way, some of the digits are

Re: [R] Frequency and Phase Spectrograms

2007-12-06 Thread Dieter Menne
Todd Remund tkremund98 at hotmail.com writes: I know that there is a function, (spectro3D), that produces the Power Spectrogram. Are there R functions that produce the Frequency Spectrogram and the Phase Spectrogram? Thank you for your time. fft in stats gives you all you need, possibly

[R] relationship between two factors

2007-12-06 Thread christopher snow
I have a dataset with two variables that are factors: 1) Decision Making Satisfaction (DMS), values = A - Completely, B - Mostly, C - Partly, D - Not at all 2) IT Satisfaction values (ITS), values = A - Completely, B - Mostly, C - Partly, D - Not at all I would like to produce a table (matrix)

[R] generalized linear model with mixed effects

2007-12-06 Thread Samuel Oman
Hi, I need to fit a general generalized linear model, for observations on a response Y which is Gamma-distributed and observed in clusters. So, if E(Y) = mu, then for a suitable link function f, f(mu) is a (linear) function of both fixed and random effects. Are there R packages or

Re: [R] Help rewriting looping structure?

2007-12-06 Thread Law, Jason
This will give you the percents in the same order as your original data (as this is what your original code did) apply(tdat, 2, function(x) { o - order(x) oldo - order(o) prc - cumsum(x[o]) / sum(x) prc[oldo] }) Jason Law Statistician City of Portland, Bureau of

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Greg Snow
Try inserting \n into the title where you would like it to start on a new line, e.g.: plot(A,main=This is my really long title\nand it's so long\nthat I can see just about half of it.) You may need to give yourself more room in the margin for multi-line titles (see ?par and the mar entry) and

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Marc Schwartz
On Thu, 2007-12-06 at 07:16 -0800, Svempa wrote: I want to fit a fairly long main title for a plot, supposedly by changing row after a while. As for now it starts way outside the picture margin at the left and continues way out right passed the right margins. plot(A,main=This is my really

Re: [R] differences in using source() or console

2007-12-06 Thread Duncan Murdoch
On 12/6/2007 8:01 AM, vito muggeo wrote: Dear all, Is there *any* reason explaining what I describe below? Probably, but you're unlikely to get a correct explanation if you don't give us code to reproduce the problem. From the look of things, your real example is quite complex, which is

Re: [R] Fitting large titles in a plot

2007-12-06 Thread jim holtman
try this: plot(0, main=paste(strwrap(This is my really long title and it's so long that I can see just about half of it., width=50), collapse=\n)) On Dec 6, 2007 7:16 AM, Svempa [EMAIL PROTECTED] wrote: I want to fit a fairly long main title for a plot, supposedly by changing row after a

Re: [R] merge in function

2007-12-06 Thread Marc Schwartz
On Thu, 2007-12-06 at 09:27 -0800, qian z wrote: I used merge() in a function, but it doesn't return correct data frame. add.name - function(data, x) { ... ... newfile - merge(data, resid, by =0, all.x=TRUE, all.y= FALSE) newfile } You are

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Jim Price
I wrote a little utility function for exactly this reason, which I use with long titles. You may want to add calls to par to adjust the upper margin if you are using raw graphical functionality (plot et al) - but lattice adjusts the upper margin automatically so you wouldn't need to add anything

[R] Randomizing one column in the dataMatrix

2007-12-06 Thread mogra
I have huge data file, and I would like randomize just one column at a time , is there any easy way? Thanks a lot. -- View this message in context: http://www.nabble.com/Randomizing-one-column-in-the-dataMatrix-tf4957535.html#a14197423 Sent from the R help mailing list archive at Nabble.com.

Re: [R] Using expression in Hmisc Key()

2007-12-06 Thread Dieter Menne
Michael Kubovy kubovy at virginia.edu writes: This is one of the cases where I wish there were a function that exercised all the arguments of a graphics function by visualizing the effect of changing two or three levels of each argument (one by one, of course). This might have the

Re: [R] Vertical text in a plot

2007-12-06 Thread John Kane
op - par(mar=(c(5, 4, 4, 4) + 0.1)) plot(1:25,runif(25,0,1),ylab=First Y-axis label,xaxt=n) axis(4,at=seq(0.2,1,.2), labels=1:5) mtext(Second Y-axis label,side=4, line=2) par(op) --- Marcin Kozak [EMAIL PROTECTED] wrote: Hi, Consider this simple plot: plot(1:25,runif(25,0,1),ylab=First

Re: [R] relationship between two factors

2007-12-06 Thread Henrique Dallazuanna
Try this: df - data.frame(DMS=factor(rep(LETTERS[1:4], 10)), ITS=factor(rep(LETTERS[1:4], 10))) table(df) plot(table(df)) -- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40 S 49° 16' 22 O On 06/12/2007, christopher snow [EMAIL PROTECTED] wrote: I have a dataset with two variables that

[R] finding most highly transcribed genes - ranking, sorting and subsets?

2007-12-06 Thread alison waller
Hello, I am not only interested in finding out which genes are the most highly up- or down-regulated (which I have done using the linear models and Bayesian statistics in Limma), but I also want to know which genes are consistently highly transcribed (ie. they have a high intensity in the

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Bert Gunter
Try This: plot(A,main=paste(This is my really long title and,\n,it's so long that I can see just about half of it., sep = )) -- Bert Gunter Genentech __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read

[R] lm.influence under R2.6.1

2007-12-06 Thread Gerard Tromp
Greetings! Recently when I tried to use lm.influence I get the following error: Error in .Fortran(lminfl, model$qr$qr, n, n, k, as.integer(do.coef), : Fortran symbol name lminfl not in DLL for package base This occurs on both Linux and Windows platforms (details below). Searching the mail

Re: [R] relationship between two factors

2007-12-06 Thread Greg Snow
The 'table' function will give you the simple counts. Plotting a table with the 'plot' function gives common charts for this. The 'CrossTable' function in the gmodels package creates the table along with additional information. There are a lot of other functions for creating/working with tables

[R] S3 and S4 clash

2007-12-06 Thread Spencer Graves
Hello: How can I work around the conflict between the S3 and S4 illustrated in the example below? I'm developing a package that requires a function in 'stats4', but when 'stats4' is attached, it breaks my AIC function. I could give my AIC function another name so it no longer uses

Re: [R] relationship between two factors

2007-12-06 Thread Marc Schwartz
On Thu, 2007-12-06 at 12:51 +, christopher snow wrote: I have a dataset with two variables that are factors: 1) Decision Making Satisfaction (DMS), values = A - Completely, B - Mostly, C - Partly, D - Not at all 2) IT Satisfaction values (ITS), values = A - Completely, B - Mostly, C

Re: [R] Java parser for R data file?

2007-12-06 Thread David Coppit
On 12/5/07 12:15 PM, Prof Brian Ripley [EMAIL PROTECTED] wrote: On Wed, 5 Dec 2007, David Coppit wrote: Or, given that I'm dealing with just a single array, would it be better to roll my own I/O using write.table or write.matrix from the MASS package? It would be much easier. The save()

[R] simple problems

2007-12-06 Thread marciarr
Hello R users, I have been looking through Help files and Nabble list for the answers for these simple questions, but it seems to be fruitless. 1- in a data frame with two columns, x and y, how do I get the corresponding value of x to, let's say, the minimum value of the y column (min (data$y)) ?

Re: [R] relationship between two factors

2007-12-06 Thread John Kane
?table should work table (DMS, ITS) I am not clear on what kind of chart you want. will plot(DMS, ITS) do what you want? --- christopher snow [EMAIL PROTECTED] wrote: I have a dataset with two variables that are factors: 1) Decision Making Satisfaction (DMS), values = A - Completely,

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Marc Schwartz
On Thu, 2007-12-06 at 09:28 -0800, Jim Price wrote: I wrote a little utility function for exactly this reason, which I use with long titles. You may want to add calls to par to adjust the upper margin if you are using raw graphical functionality (plot et al) - but lattice adjusts the upper

Re: [R] lm.influence under R2.6.1

2007-12-06 Thread Marc Schwartz
On Thu, 2007-12-06 at 14:00 -0500, Gerard Tromp wrote: Greetings! Recently when I tried to use lm.influence I get the following error: Error in .Fortran(lminfl, model$qr$qr, n, n, k, as.integer(do.coef), : Fortran symbol name lminfl not in DLL for package base This occurs on both

[R] Course***January 2008 *** San Francisco New York City *** R/S-Plus Advanced Programming by XLSolutions Corp

2007-12-06 Thread [EMAIL PROTECTED]
Happy Holidays Folks! XLSolutions Corporation has scheduled 2 great R/Splus Advanced programming courses. More course can be viewed on our website. R/Splus Advanced Programming* San Francisco January 21-22, 2008 R/Splus Advanced Programming* New York City January 24-25,

Re: [R] Fitting large titles in a plot

2007-12-06 Thread Jim Price
I have learned something new - thanks for the strwrap info. The problem with posting from Nabble is that by the time your post actually gets to the list (2 hours after you posted it in this case) and you've written some line like Knowing the R list, someone can probably reduce this function to 2

Re: [R] S3 and S4 clash

2007-12-06 Thread Prof Brian Ripley
I'd say that was pretty clearly a bug in stats4 (which as I recall was needed to get around the scoping awkwardnesses of S4). But could you not write a logLik method for your class? E.g. logLik.bar - function(object, ...) structure(pi, class=logLik, df=1) AIC(bar.tmp) [1] -4.283185

Re: [R] Java parser for R data file?

2007-12-06 Thread kchine
Dear David, You may also consider using the biocep project' tools and frameworks. they provide an advanced bridge that allow you to exchange between R and Java any standard R Object and any mapped S4 object. the object extracted to Java (an RList for you data) can be serialized to a file (saved

[R] Integral implicit function

2007-12-06 Thread Eddy H. G. Bekkers
Hi, Could somebody help me with the following. I want to calculate the integral over an implicit function. I thought to integrate over a function depending on uniroot. In previous topics I found a thread about finding the root of an integral. And that works. But the other way around, does not

[R] coxme() random effect syntax

2007-12-06 Thread Justin Montemarano
Hello: I would like to run a Cox proportional hazards regression on crayfish dislodgement at different water velocities by crayfish size class and substrate (rock) type. Additionally, there is a covariate variable, rock movement that may be influencing crayfish dislodgment. So... I have

Re: [R] simple problems

2007-12-06 Thread Domenico Vistocco
marciarr wrote: Hello R users, I have been looking through Help files and Nabble list for the answers for these simple questions, but it seems to be fruitless. 1- in a data frame with two columns, x and y, how do I get the corresponding value of x to, let's say, the minimum value of the y

[R] row lables in heatmap.2()

2007-12-06 Thread affy snp
Dear list, I am wondering if there are any parameters in heatmap.2 to be able to adjust the size of row labels. Or the size of the plot can be made smaller. The plot I got is big and cannot see the full row labels completely. And what is the maximum of rows which could allow row labels visible

[R] Testing Two Categorical Variable

2007-12-06 Thread ramin . 1981
The chi-square does not need your two categorical variables to have equal levels, nor limitation for the number of levels. The Chi-square procedure is as follow: χ^2=∑_(All Cells)▒〖(Observed-Expected)〗^2/Expected Expected Cell= E_ij=n((i^th RowTotal)/n)((j^th RowTotal)/n) Degree of Freedom=df=

[R] Testing Two Categorical Variable

2007-12-06 Thread ramin . 1981
The chi-square does not need your two categorical variables to have equal levels, nor limitation for the number of levels. The Chi-square procedure is as follow: χ^2=∑_(All Cells)▒〖(Observed-Expected)〗^2/Expected Expected Cell= E_ij=n((i^th RowTotal)/n)((j^th RowTotal)/n) Degree of Freedom=df=

[R] updating a helper function in a R package

2007-12-06 Thread Tao Shi
Hi list, Sorry for the vague title, but here is the scenario. I’m writing an R package, let’s say, ‘pkg1’, which contains 3 functions: f1, f2, f3. f2 and f3 are helper functions for f1, i.e. f1 calls f2 which in turn calls f3. f1 - function(…) { …. f2() … } f2 -

Re: [R] simple problems

2007-12-06 Thread Gabor Grothendieck
On Dec 6, 2007 3:26 PM, marciarr [EMAIL PROTECTED] wrote: Hello R users, I have been looking through Help files and Nabble list for the answers for these simple questions, but it seems to be fruitless. 1- in a data frame with two columns, x and y, how do I get the corresponding value of x

Re: [R] updating a helper function in a R package

2007-12-06 Thread Gabor Grothendieck
If you are using namespaces see: ?assignInNamespace On Dec 6, 2007 5:38 PM, Tao Shi [EMAIL PROTECTED] wrote: Hi list, Sorry for the vague title, but here is the scenario. I'm writing an R package, let's say, 'pkg1', which contains 3 functions: f1, f2, f3. f2 and f3 are helper functions

[R] How can I plot this graph

2007-12-06 Thread David Rees
Hi, I am having trouble plotting the graph I need given the follow kind of data xxx - data.frame( x=c(1,2,3,4,5), y1=c(2,4,3,5,6), y2=c(3,4,6,3,1), y3=c(1,3,5,7,3), z1=c(1,NA,3,5,NA), z2=c(2,NA,4,6,NA) )

  1   2   >