Re: [R] searching and replacing in a data frame.

2011-07-18 Thread Joshua Wiley
Hi, A slight modification corrects this: ttt - data.frame(A = c(Inf, 0, 0), B = c(1, 2, 3)) apply(ttt, 2, function(x) {x[is.infinite(x)] - 0; x}) and please do use spaces in your code. It is much more legible. Most notably spaces are after commas. Cheers, Josh On Sun, Jul 17, 2011 at 10:01

Re: [R] searching and replacing in a data frame.

2011-07-18 Thread Ashim Kapoor
ttt - data.frame(A = c(Inf, 0, 0), B = c(1, 2, 3)) apply(ttt, 2, function(x) {x[is.infinite(x)] - 0; x}) Ok thank you. That does work. What does apply(ttt, 1, function(x) x[is.infinite(x)] - 0 ) this return. I get all 0's,but can you explai why ? Thank you. Ashim [[alternative

Re: [R] RMySQL, RODBC, dbReadTable and ISO-8859-1 (Spanish data)

2011-07-18 Thread Carlos Ortega
Hola Mario, No sé si finalmente pudiste solucionar el problema que planteaste, por si todavía lo tienes te sugiero que incluyas el correo en la lista de ayuda de R pero en español R-help-es. Puedes darte de alta aquí: https://stat.ethz.ch/mailman/listinfo/r-help-es Saludos, Carlos Ortega

Re: [R] searching and replacing in a data frame.

2011-07-18 Thread Joshua Wiley
On Mon, Jul 18, 2011 at 12:22 AM, Ashim Kapoor ashimkap...@gmail.com wrote:     ttt - data.frame(A = c(Inf, 0, 0), B = c(1, 2, 3)) apply(ttt, 2, function(x) {x[is.infinite(x)] - 0; x}) Ok thank you. That does work. What does apply(ttt, 1, function(x) x[is.infinite(x)] - 0 ) this return.

Re: [R] ?Accuracy of prop.test

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 01:11 , Rolf Turner wrote: This more sophisticated solution is a pain in the pohutukawa ( :-) ) to calculate by hand, but if you've got a computer to do the nasty arithmetic for you, then why not? Yes. Notice the irony: Textbook authors choose the simplest

[R] BEKK help?

2011-07-18 Thread cchere
I used mgarch and mgarchBEKK packages to esti,ate a BEKK model ,but i cannot get the P-value of the coefficient , how can I get P-value ,anyone can help me ? thanks -- View this message in context: http://r.789695.n4.nabble.com/BEKK-help-tp3674545p3674545.html Sent from the R help

Re: [R] Splitting one column value into multiple rows

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 06:09 , David Winsemius wrote: PFB What ever that TLA means Just google for it: Postcard from Buster ;-) -- Peter Dalgaard Center for Statistics, Copenhagen Business School Solbjerg Plads 3, 2000 Frederiksberg, Denmark Phone: (+45)38153501 Email: pd@cbs.dk

Re: [R] searching and replacing in a data frame.

2011-07-18 Thread Ashim Kapoor
Ok Josh. Many thanks for your effort. Ashim : ) On Mon, Jul 18, 2011 at 1:34 PM, Joshua Wiley jwiley.ps...@gmail.comwrote: On Mon, Jul 18, 2011 at 12:22 AM, Ashim Kapoor ashimkap...@gmail.com wrote: ttt - data.frame(A = c(Inf, 0, 0), B = c(1, 2, 3)) apply(ttt, 2, function(x)

Re: [R] nls() and lines()

2011-07-18 Thread Peter Ehlers
On 2011-07-17 17:37, Steven Ranney wrote: All - I'm having an issue with trying to plot a model derived from nls() onto a simple plot. I have included a sample data set and the code that I've been using. year month day date location mileage cost gallon cpg mpg x

Re: [R] Splitting one column value into multiple rows

2011-07-18 Thread Berend Hasselman
Peter Dalgaard-2 wrote: On Jul 18, 2011, at 06:09 , David Winsemius wrote: PFB What ever that TLA means Just google for it: Postcard from Buster ;-) offtopic I did and found this gem for PFB Pseudofolliculitis barbae, a medical term for persistent inflammation caused by

[R] cluster by unique value

2011-07-18 Thread Alfredo Alessandrini
Hi, I need to make a cluster classification by the unique values of the data frame. I explain the problem. I need to classify this table, and assign to the same cluster each row that has the same combination of value: data1 layer_1 layer_2 layer_3 [1,] 0.246000 2

Re: [R] cluster by unique value

2011-07-18 Thread Sarah Goslee
Your data1 and your data1_class file differ in the first three columns. Assuming that's an error, here's one way to do it: data1 - data.frame(layer1=c(.2, .5, .2, .8, .2, .5, .5, .8, .2, .8),layer2=c(2,3,2,2,1,2,3,2,2,2), layer3=c(1,1,1,1,1,1,1,1,1,4)) data1 - cbind(data1,

Re: [R] Number in interval

2011-07-18 Thread Manuel K.
Thank you Jim, Steve and David. I found findIntervals to work best for my problem. Manuel -- View this message in context: http://r.789695.n4.nabble.com/Number-in-interval-tp3673537p3674969.html Sent from the R help mailing list archive at Nabble.com.

[R] write merged data frame to a file

2011-07-18 Thread Andrea Franceschini
Dear all, I merged 2 data frames using the merged command and the resulting data frame looks perfect into R. However, I have serious problems when I try to write this new data frame into a file using the write.table command. Basically I get parts of the second file that I merged into the file.

Re: [R] cluster by unique value

2011-07-18 Thread jim holtman
Also read FAQ 7.31 before using 'numerics' as grouping factors. On Mon, Jul 18, 2011 at 6:36 AM, Sarah Goslee sarah.gos...@gmail.com wrote: Your data1 and your data1_class file differ in the first three columns. Assuming that's an error, here's one way to do it: data1 -

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread Gabor Grothendieck
On Sat, Jul 16, 2011 at 11:50 PM, Eduardo M. A. M. Mendes emammen...@gmail.com wrote: Hello I am new to R and I need to convert some dates (numeric format by matlab) to actual dates in R. For instance, Matlab - 730456 - datestr(730456) ans = 02-Dec-1999 Set the origin to Matlab's

Re: [R] Out of Sample Prediction Interval/Point Estimate

2011-07-18 Thread Zd Gibbs
it's not possible to look for a local statistical consultatnt. I was just hoping for help. Thanks anyway. From: Uwe Ligges lig...@statistik.tu-dortmund.de Cc: r-help@r-project.org Sent: Sun, July 17, 2011 9:27:22 AM Subject: Re: [R] Out of Sample Prediction

[R] 1st Data Analysis Contest Using R

2011-07-18 Thread Emilio Torres Manzanera
1st Data Analysis Contest Using R Nestoria is a specialized web search engine platform in house prices. Nestoria y Lokku Labs aim to improve the understanding of the public of the value of its databases. The company aims to engage a few brilliant statisticians in the expectation that their

Re: [R] write merged data frame to a file

2011-07-18 Thread Sarah Goslee
Hi Andrea, On Mon, Jul 18, 2011 at 6:07 AM, Andrea Franceschini ata...@gmail.com wrote: Dear all, I merged 2 data frames using the merged command and the resulting data frame looks perfect into R. However, I have serious problems when I try to write this new data frame into a file using

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 14:08 , Gabor Grothendieck wrote: On Sat, Jul 16, 2011 at 11:50 PM, Eduardo M. A. M. Mendes emammen...@gmail.com wrote: Hello I am new to R and I need to convert some dates (numeric format by matlab) to actual dates in R. For instance, Matlab - 730456 -

Re: [R] ?Accuracy of prop.test

2011-07-18 Thread Jack Sofsky
Ted, Rolf Peter, Thanks for a truly educational (at least for me) thread. I did indeed look up the article /Interval Estimation for the Difference Between Independent Proportions: Comparison of Eleven Methods. /which I found here.

[R] SDMTools package - calculating overlap?

2011-07-18 Thread Ana Kolar
Dear R users, Any idea of how to calculate an area of an overlap between two functions? The only R build in function that I found is I Similarity Statistic for Quantifying Niche Overlap and I am really not sure if this function is producing exactly what I am interested in since I was plotting

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 9:40 AM, Ana Kolar wrote: Dear R users, Any idea of how to calculate an area of an overlap between two functions? The only R build in function that I found is I Similarity Statistic for Quantifying Niche Overlap and I am really not sure if this function is producing

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread Gabor Grothendieck
On Mon, Jul 18, 2011 at 8:56 AM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 14:08 , Gabor Grothendieck wrote: On Sat, Jul 16, 2011 at 11:50 PM, Eduardo M. A. M. Mendes emammen...@gmail.com wrote: Hello I am new to R and I need to convert some dates (numeric format by

[R] plotting groups via density and different colors

2011-07-18 Thread Jacob Kasper
I have a data set that looks like this: dene - data.frame(length = c(35,32,33,34,41,40,46,35,41,40,45,36,38,37,39,40,42,42,42,43,44), sex=c(1,1,1,1,2,2,2,1,2,2,2,1,2,2,2,2,2,2,2,2,2)) I would like to plot the density (frequency of occurrence) of each length class but I want to have different

Re: [R] nls() and lines()

2011-07-18 Thread Peter Ehlers
On 2011-07-18 06:38, Steven Ranney wrote: Provided, of course, that I alter the lines for different data sets and data frames, the code to plot a line derived from nls() onto a plot works with no problems. Here's an example: Year NOP 2002 6 2003 8 2004 11 2005 19 2006 26 2007 25 mod1-

Re: [R] ?Accuracy of prop.test

2011-07-18 Thread Peter Ehlers
You might also enjoy the binconf() function in the Hmisc pkg. Peter Ehlers On 2011-07-18 06:17, Jack Sofsky wrote: Ted, Rolf Peter, Thanks for a truly educational (at least for me) thread. I did indeed look up the article /Interval Estimation for the Difference Between Independent

Re: [R] write merged data frame to a file

2011-07-18 Thread Andrea Franceschini
Dear all, Sarah, ok, I start to give some details. I use version 13 of R in OSX (downloaded and installed less than 1 year ago). I pasted below the results of the str() command. The data frame looks perfect for me. I generated the dataframe using the following commands:

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 15:48 , Gabor Grothendieck wrote: On Mon, Jul 18, 2011 at 8:56 AM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 14:08 , Gabor Grothendieck wrote: On Sat, Jul 16, 2011 at 11:50 PM, Eduardo M. A. M. Mendes emammen...@gmail.com wrote: Hello I am new to

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread Ana Kolar
Yes, indeed! I believe I should integrate differences of min of both functions, no? I'm not quite sure how this should be done in R therefore I was wondering if there are some build in functions that do this job already. If not I would appreciate any help of how should it be done otherwise.

Re: [R] Survival Analysis

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 10:10 AM, Kishor Tappita wrote: Dear David, Thank you for your reply. I realized that the summary function can help me in finding the the order of the curves. The 0.95UCL (95% upper confidence level) column in particular seems to follow the same pattern as the

Re: [R] Survival Analysis

2011-07-18 Thread Kishor Tappita
Dear David, Thank you for your reply. I realized that the summary function can help me in finding the the order of the curves. The 0.95UCL (95% upper confidence level) column in particular seems to follow the same pattern as the curves on the plot. I am new to survival analysis, so please

Re: [R] nls() and lines()

2011-07-18 Thread Steven Ranney
Provided, of course, that I alter the lines for different data sets and data frames, the code to plot a line derived from nls() onto a plot works with no problems. Here's an example: Year NOP 2002 6 2003 8 2004 11 2005 19 2006 26 2007 25 mod1 - nls(NOP~alpha*exp(beta*Year), data=aic,

Re: [R] nls() and lines()

2011-07-18 Thread Steven Ranney
Unfortunately, the transposition of lines and list was a typo on my part. Now that I look like a fool and have corrected the issue, I'm still faced with the same dilemma. With the original data set I posted in this thread, plot(mpg~x, data=mileage[year==2009,], ylab=Miles per gallon, xlab=2009,

Re: [R] write merged data frame to a file

2011-07-18 Thread Philipp Pagel
On Mon, Jul 18, 2011 at 04:00:29PM +0200, Andrea Franceschini wrote: I use version 13 of R in OSX (downloaded and installed less than 1 year ago). Probably 2.13 ... [...] code omitted The first lines are OK (i.e. 14 columns, like the dataframe), while at a certain point I get lines with

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread Gabor Grothendieck
On Mon, Jul 18, 2011 at 10:08 AM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 15:48 , Gabor Grothendieck wrote: On Mon, Jul 18, 2011 at 8:56 AM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 14:08 , Gabor Grothendieck wrote: On Sat, Jul 16, 2011 at 11:50 PM,

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 10:11 AM, Ana Kolar wrote: Yes, indeed! I believe I should integrate differences of min of both functions, no? I'm not quite sure how this should be done in R therefore I was wondering if there are some build in functions that do this job already. If not I would

Re: [R] Survival Analysis

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 10:42 AM, Kishor Tappita wrote: Ok David, Thanks for clearing my misconception. Then could you please suggest me how I could get the KM estimate for a time point. I remember reading the formula for calculating the KM. Do, I have to write a method to compute the KM

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread Ana Kolar
Dear David, The toy example doesn't represent functions as such, but represents type of data that I'm operating with. These data are product of an analysis. If I understand you correctly, I would need to approximate distribution functions of these data first and then integrate. This makes

Re: [R] write merged data frame to a file

2011-07-18 Thread Andrea Franceschini
Dear Philipp, You were right, thankyou very much. Effectively the second read.table didn't work (probably because of the strange characters). From my point of view this is a very bad R bug. I precisely inserted the \t separator in the read table command, hence I would expect that everything is

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 11:07 AM, Ana Kolar wrote: Dear David, The toy example doesn't represent functions as such, but represents type of data that I'm operating with. These data are product of an analysis. If I understand you correctly, I would need to approximate distribution functions

[R] useR! 2011, late registration deadline this Friday (22 July)

2011-07-18 Thread David Firth
This is just a gentle reminder of the final registration deadline for this year's useR! conference (University of Warwick, 16-18 August; tutorials 15 August). No further registrations will be accepted after this Friday (22 July). Contributions to the conference programme can still be offered as

[R] Strange graphs

2011-07-18 Thread UnitRoot
Hello, I am facing problems with plotting graphs in R. It was working well since today, but I cannot get some graphs for unknown reasons. Initially it gave me diagonal straight lines. Now it is giving me very strange curves. I have tried to re-install the softwear. It still did not help. Please,

[R] Missing values and geeglm

2011-07-18 Thread E
Dear all I am struggling with how to deal with missing values using geeglm. I know that geeglm only works with complete datasets, but I cannot seem to get the na.omit function to work. For example assuming DataMiss contains 3 columns, each of which has missing observations, and an id column

Re: [R] Survival Analysis

2011-07-18 Thread Kishor Tappita
Ok David, Thanks for clearing my misconception. Then could you please suggest me how I could get the KM estimate for a time point. I remember reading the formula for calculating the KM. Do, I have to write a method to compute the KM estimate or will the survival package provide it for me? Thank

Re: [R] Survival Analysis

2011-07-18 Thread Kishor Tappita
Thanks a lot. I used survfit to generate KM plots but I will try to figure out to find the corresponding returned value for KM estimate. Thank you for your invaluable help. On Mon, Jul 18, 2011 at 8:28 PM, David Winsemius dwinsem...@comcast.netwrote: On Jul 18, 2011, at 10:42 AM, Kishor

Re: [R] SDMTools package - calculating overlap?

2011-07-18 Thread Ana Kolar
Many thanks for this, David. It is applicable, indeed! Thank you for sharing the search function as well.  Have a good day! Ana From: David Winsemius dwinsem...@comcast.net To: Ana Kolar annako...@yahoo.com Cc: R r-help@r-project.org Sent: Monday, 18 July

[R] Extract confidence intervals from rma object (metafor package)

2011-07-18 Thread Jokel Meyer
Dear R-experts! I am working on some meta-analysis using the metafor package. I would like to extract values of the confidence intervals of the effect sizes of the single studies from an rma object. Those values are printed out when plotting a forest plot using the forest function on the rma

[R] PCA - princomp can only be used with more units than variables

2011-07-18 Thread a.me...@yahoo.co.uk
Hi, May I ask a question about a thread https://stat.ethz.ch/pipermail/r-help/2005-March/068365.html? I understand I need to use prcomp instead of princomp when i have less units than variables. However, when I use prcomp the scores is NULL. How can I overcome this? Regards, Armin -- Kind

Re: [R] barplot question

2011-07-18 Thread Sally_roman
I have done ?barplot. I have not problems making barplots in R except for this where there are actually two stacked columns for each fish. I have also searched the internet to look for examples like what I would like to plot, but have not found any which is why I thought putting a post would

Re: [R] nls() and lines()

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 10:13 AM, Steven Ranney wrote: Unfortunately, the transposition of lines and list was a typo on my part. Now that I look like a fool and have corrected the issue, I'm still faced with the same dilemma. With the original data set I posted in this thread, No. You did not

Re: [R] barplot question

2011-07-18 Thread Sarah Goslee
Hi Sally, I'm not sure what your question actually is. How to make a stacked bar plot, perhaps? If so, do any of the examples at these two sites help? http://www.harding.edu/fmccown/R/#barcharts http://addictedtor.free.fr/graphiques/search.php?engine=RGGq=barplot If not, can you explain what

Re: [R] PCA - princomp can only be used with more units than variables

2011-07-18 Thread Joshua Wiley
Hi, You need to explain what you want to do. This is not a software issue, you simply cannot create more uncorrelated variables than you have observations. Josh On Mon, Jul 18, 2011 at 8:53 AM, a.me...@yahoo.co.uk a.me...@yahoo.co.uk wrote: Hi, May I ask a question about a thread

Re: [R] write merged data frame to a file

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 11:10 AM, Andrea Franceschini wrote: Dear Philipp, You were right, thankyou very much. Effectively the second read.table didn't work (probably because of the strange characters). From my point of view this is a very bad R bug. When I read this I thought it was an

Re: [R] Rmpi fails to install

2011-07-18 Thread Juergen Rose
Am Sonntag, den 03.07.2011, 18:19 +0200 schrieb r...@rz.uni-potsdam.de: Quoting r...@rz.uni-potsdam.de: Quoting Juergen Rose r...@rz.uni-potsdam.de: Hi, I was just able to install the patched Rmpi on the second system with openmpi-1.5.3. What can we that Rmpi_0.5-9a.tar.gz becomes a

Re: [R] Extract confidence intervals from rma object (metafor package)

2011-07-18 Thread Viechtbauer Wolfgang (STAT)
Dear Jokel, Right now, none of the functions return that information. But it's easy to calculate those CIs by hand (simply take yi +- 1.96 sqrt(vi) and apply, if needed, some appropriate transformation). For example: data(dat.bcg) dat - escalc(measure=RR, ai=tpos, bi=tneg, ci=cpos, di=cneg,

Re: [R] Strange graphs

2011-07-18 Thread Liviu Andronic
On Mon, Jul 18, 2011 at 5:04 PM, UnitRoot akhussa...@gmail.com wrote: Hello, I am facing problems with plotting graphs in R. It was working well since today, but I cannot get some graphs for unknown reasons. Initially it gave me diagonal straight lines. Now it is giving me very strange curves.

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 16:36 , Gabor Grothendieck wrote: . However, this was after reinstalling and reloading zoo. Restarting R and retrying did indeed make things work. Does the fact that it worked if R was restarted, but not without, imply that there is something in R that needs

Re: [R] question about linear mixed model

2011-07-18 Thread Kevin Wright
Note: PLEASE do read the posting guide http://www.R-project.org/posting-guide.htmlhttp://www.r-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Also, your question may be more appropriate for the R mixed-models mailing list. Kevin On Sun, Jul

[R] Understanding R's Environment concept

2011-07-18 Thread Nipesh Bajaj
Hi all, I am trying to understand the R's environment concept however the underlying help files look quite technical to me. Can experts here provide me some more intuitive ideas behind this concept like, why it is there, what exactly it is doing in R's architecture etc.? I mainly need some

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread Gabor Grothendieck
On Mon, Jul 18, 2011 at 1:59 PM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 16:36 , Gabor Grothendieck wrote: . However, this was after reinstalling and reloading zoo. Restarting R and retrying did indeed make things work. Does the fact that it worked if R was

Re: [R] Understanding R's Environment concept

2011-07-18 Thread Bert Gunter
This **is** an inherently technical topic. Did you try the R Language Manual section on environments (wasn't clear from your message)? You might try posting on R-devel. Folks there may know of tutorials/books that might be useful to you. -- Bert On Mon, Jul 18, 2011 at 11:16 AM, Nipesh Bajaj

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread peter dalgaard
On Jul 18, 2011, at 20:19 , Gabor Grothendieck wrote: On Mon, Jul 18, 2011 at 1:59 PM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 16:36 , Gabor Grothendieck wrote: . However, this was after reinstalling and reloading zoo. Restarting R and retrying did indeed make

Re: [R] barplot question

2011-07-18 Thread Sally_roman
I would like to make stacked barplots, but with two stacked columns per x value. For cod - I have kept and discard values for 2 nets. I would like to have one stacked column for the control net with the kept and discard value and then another column with the kept and discard values for the

[R] cforest - keep.forest = false option?

2011-07-18 Thread KHOFF
Hi, I'm very new to R. I am most interested in the variable importance measures that result from randomForest, but many of my predictors are highly correlated. My first question is: 1. do highly correlated variables render variable importance measures in randomForest invalid? and 2. I know that

[R] IDE with table/matrix preview

2011-07-18 Thread Michael Bernsteiner
I know there are several threads about IDEs for R. I've tried Tinn-R, but I am looking for an IDE (win) with a preview function that shows me the variables and the table/matrix etc. when klicking. (comparable to Matlab). Does an IDE like this exist or can't IDEs give this functionality in R?

[R] line jump in plot legend title

2011-07-18 Thread Dutrieux , Loïc
Hello, In order to reduce the width of my legend in a plot I introduced line jumps in the title. Here's the problem; the legend box hasn't adapted accordingly and part of the title is printed out of the frame. See the example below: plot(1:10) legend(bottomright, bg=white,

[R] [SDMtools] how to calculate total edge of patch excluding landscape boundary

2011-07-18 Thread Insu Koh
Hi, R users, I have a question about using ClassStat in SDMtools. I want to calculate total edge of patch; however, according to FRAGSTAT, the total.edge value of ClassStat means that total length (m) of edge in landscape involving patch type (class) i; includes landscape boundary and background

Re: [R] Drawing a histogram from a massive dataset

2011-07-18 Thread Paul Smith
Thanks, Dennis, for your suggestions. I was thinking about the package 'sqldf', but I guess that I must have a data frame to plot a histogram. Paul On Fri, Jul 15, 2011 at 4:15 PM, Dennis Murphy djmu...@gmail.com wrote: I would suggest that you avoid the histogram and make a density plot

Re: [R] Understanding R's Environment concept

2011-07-18 Thread Barry Rowlingson
On Mon, Jul 18, 2011 at 7:16 PM, Nipesh Bajaj bajaj141...@gmail.com wrote: Hi all, I am trying to understand the R's environment concept however the underlying help files look quite technical to me. Can experts here provide me some more intuitive ideas behind this concept like, why it is

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread Gabor Grothendieck
On Mon, Jul 18, 2011 at 2:57 PM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 20:19 , Gabor Grothendieck wrote: On Mon, Jul 18, 2011 at 1:59 PM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 16:36 , Gabor Grothendieck wrote: . However, this was after

[R] Installation of rblas package (R interface to the BLAS and LAPACK)

2011-07-18 Thread Madan Kundu
Hi, I am trying to install the package rblas which is an R interface to the BLAS and LAPACK libraries. I have downloaded the rblas.tar from

[R] np package, estimating the standard errors of Klein and Spady's estimator

2011-07-18 Thread Dimitris.Kapetanakis
Dear all, I would like to estimate the standard errors of Klein and Spady's estimator for that I am using: library(np) N-100 X-matrix(c(rnorm(N,1,1), rnorm(N,0,1)), ncol=2) BETA -matrix(1,2,1) Z-X%*%BETA L-rlogis(N,location=0, scale=1) Y -as.vector(X%*%BETA+L=0)*1 KS - npindexbw (xdat=X,

[R] heatmap with RNA-Seq data

2011-07-18 Thread rebioman
Hi all, new to this forum I'm try to using R to draw a heatmap of my RNA-seq data before doing that I did a log2 transformation of my data and produce a lot -inf in the matrix when I try to use the heatmap function, it seems can not deal with the -inf so I was wondering how to deal with these

Re: [R] line jump in plot legend title

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 1:14 PM, Dutrieux, Loïc wrote: Hello, In order to reduce the width of my legend in a plot I introduced line jumps in the title. Here's the problem; the legend box hasn't adapted accordingly and part of the title is printed out of the frame. See the example below:

[R] Problem compiling in extra/xdr

2011-07-18 Thread Allin Cottrell
I'm building R 2.13.1 on i686-pc-linux-gnu, using gcc 4.6.1 and with glibc 2.14. I get this error: In file included from xdr.c:61:0: ./rpc/types.h:63:14: error: conflicting types for 'malloc' make[4]: *** [xdr.o] Error 1 I can make the build proceed some by commenting out the declaration

Re: [R] heatmap with RNA-Seq data

2011-07-18 Thread David Winsemius
On Jul 18, 2011, at 3:34 PM, rebioman wrote: Hi all, new to this forum I'm try to using R to draw a heatmap of my RNA-seq data before doing that I did a log2 transformation of my data and produce a lot -inf in the matrix when I try to use the heatmap function, it seems can not deal with

Re: [R] Drawing a histogram from a massive dataset

2011-07-18 Thread Joshua Wiley
On Mon, Jul 18, 2011 at 10:57 AM, Paul Smith phh...@gmail.com wrote: [snip] I guess that I must have a data frame to plot a histogram. Not at all! ## a *vector* of 100 million observation x - rnorm(10^8) ## a histogram for it (see attached for the result from my system) hist(x) No data frame

Re: [R] special question on regression

2011-07-18 Thread Greg Snow
I remember seeing an example using the EM algorithm where one of the variables was age of child and they assumed that an age like 16 months was accurate to the month, but ages like 18 months may have been off by as much as 2 months and ages like 3 years could be off by 6 months (or more), so

Re: [R] How to speed up interpolation

2011-07-18 Thread James Rome
There is one problem. No matter what I do, I can't recover the correct runway in the final list. You had rw = as.numeric(df$lrw) # index into 'levels' I have tried df$lrw = factor(df$lrw, ordered=TRUE) rwys = factor(unique(df$lrw), ordered=TRUE)# Get the names of the runways rwys

Re: [R] Number in interval

2011-07-18 Thread Greg Snow
A small modification of this would be: library(TeachingDemos) -3 %=% z %=% 3 Whether that is prettier or uglier than Jim's answer is in the eye of the beholder (for longer variable names this version could save a few key strokes). -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center

Re: [R] ?Accuracy of prop.test

2011-07-18 Thread Greg Snow
Others have explained why R gives a different answer based on a different approximation, but if you want to get the same answer as the book/minitab/... for your own understanding (or so the grader doesn't get confused by superior answers, or other reasons) here is one way to do it: x - c(

Re: [R] IDE with table/matrix preview

2011-07-18 Thread Steven Kennedy
Try RStudio. It is the best IDE for R I've seen. On Tue, Jul 19, 2011 at 3:31 AM, Michael Bernsteiner dethl...@hotmail.com wrote: I know there are several threads about IDEs for R. I've tried Tinn-R, but I am looking for an IDE (win) with a preview function that shows me the variables and

Re: [R] customize output in Excel and creating reports in word.

2011-07-18 Thread Greg Snow
There are several options depending on what exactly you want to do. If you use code like: write.table(x, 'clipboard', sep='\t') In R, then go to excel and choose a cell and paste to it, the matrix or data frame 'x' will be pasted into excel at that point (topleft corner of data goes in

Re: [R] Drawing a histogram from a massive dataset

2011-07-18 Thread Paul Smith
On Mon, Jul 18, 2011 at 9:11 PM, Joshua Wiley jwiley.ps...@gmail.com wrote: [snip] I guess that I must have a data frame to plot a histogram. Not at all! ## a *vector* of 100 million observation x - rnorm(10^8) ## a histogram for it (see attached for the result from my system) hist(x) No

Re: [R] Number in interval

2011-07-18 Thread William Dunlap
Note that the precendence of %=% is not the same as that of =, so you can be surprised by its behavior in slightly more complex expressions: z - seq(1.2, len=5, by=.7) which( 2 %=% z %=% 3 ) # same as which(2=z z=3) [1] 3 which( 2 %=% z %=% 1.5*2 ) Error in which(2 %=% z %=% 1.5 *

[R] Doesnt' winedt 6 version work as Rwinedt?

2011-07-18 Thread Soyeon Kim
Dear All, I've tried install Rwinedt using my Winedt 6. I cannot see R tab in Rwinedt even though I followed the instruction. (Installed RWinEdt and called the library) Version 6 doesn't work? If not, if would you recommend an R editor for window user?(Except for Emacs) Thanks,

Re: [R] Number in interval

2011-07-18 Thread Greg Snow
Good point, I have added a note and example to the documentation to this effect. -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare greg.s...@imail.org 801.408.8111 -Original Message- From: William Dunlap [mailto:wdun...@tibco.com] Sent: Monday, July

[R] list of data.frames

2011-07-18 Thread Andrew Winterman
Hey there, I've got a for loop in my code which I'm having difficulty seeing how to avoid. Here's the code, with some sample data. You can safely copy and paste into the interpreter if you want. #I have some data frames. a - as.data.frame(matrix(runif(50), nrow = 10, ncol = 5)) b -

[R] Fitting a multi-level logistic model

2011-07-18 Thread Rafael Piñeiro
We are trying to fit a multi-level logistic regression and we work with public opinion data. Our dependent variable is interest in politics, a dummy variable. We have individual and group-level (country) covariates. Hence, we work with group level predictors. Actually, our theory argues that, the

Re: [R] heatmap with RNA-Seq data

2011-07-18 Thread rebioman
That what I did, I replaced the -infinite with lowest number I got from my data set. I'm not sure this kind of data manipulation is allowed in a publication -- View this message in context: http://r.789695.n4.nabble.com/heatmap-with-RNA-Seq-data-tp3676207p3676280.html Sent from the R help

[R] Correspondence Analysis of Textual Data and Visualization of Correspondence Results in a 3d plot with the ‘ca’ package.

2011-07-18 Thread gabriele
Good Evening, my aim is to perform a multiple correspondence analysis on a textual matrix by using the ‘ca’ package, which performs a 3d visualization of the results. Specifically, the frequency matrix contains words (rows) and variables (columns), and the contempt of each cell is the occurrence

Re: [R] How to convert number (matlab) to date

2011-07-18 Thread steven mosher
Thanks, I just upgraded to 1.7.1 Also thanks for adding the t() function. On Mon, Jul 18, 2011 at 12:38 PM, Gabor Grothendieck ggrothendi...@gmail.com wrote: On Mon, Jul 18, 2011 at 2:57 PM, peter dalgaard pda...@gmail.com wrote: On Jul 18, 2011, at 20:19 , Gabor Grothendieck wrote:

[R] Testers wanted for program that works with R

2011-07-18 Thread Roy Mendelssohn
Hi All: Along with Applied Sciences Associates we have been working on a GUI add-on for R that allows easy access to literally pterabytes of remote oceanographic and meteorological data that can be subsetted in time and space, and then will be brought directly into R using web services. The

[R] Using Mplus via R

2011-07-18 Thread Dimitri Liakhovitski
Clarification question: does one need Mplus installed in order to use Mplus Automation package? -- Dimitri Liakhovitski www.ninah.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] cluster by unique value

2011-07-18 Thread Petr Savicky
On Mon, Jul 18, 2011 at 06:36:13AM -0400, Sarah Goslee wrote: Your data1 and your data1_class file differ in the first three columns. Assuming that's an error, here's one way to do it: data1 - data.frame(layer1=c(.2, .5, .2, .8, .2, .5, .5, .8, .2, .8),layer2=c(2,3,2,2,1,2,3,2,2,2),

Re: [R] How to speed up interpolation

2011-07-18 Thread jim holtman
To recover the runways, try: levels(df$lrw)[times[, 'runway']] The 'runway' column has the index into 'levels(df$lrw)' On Mon, Jul 18, 2011 at 4:35 PM, James Rome jamesr...@gmail.com wrote: There is one problem. No matter what I do, I can't recover the correct runway in the final list. You

[R] R on a server (Windows Server 2008)

2011-07-18 Thread Dimitri Liakhovitski
Apologies for a naive question: Can R be installed and run on a server (operating system Windows Server 2008)? Thank you! -- Dimitri Liakhovitski __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

Re: [R] Drawing a histogram from a massive dataset

2011-07-18 Thread Joshua Wiley
On Mon, Jul 18, 2011 at 2:08 PM, Paul Smith phh...@gmail.com wrote: On Mon, Jul 18, 2011 at 9:11 PM, Joshua Wiley jwiley.ps...@gmail.com wrote: [snip] I guess that I must have a data frame to plot a histogram. Not at all! ## a *vector* of 100 million observation x - rnorm(10^8) ## a

Re: [R] ecdf() to nls() - how to transform data?

2011-07-18 Thread Jochen1980
Ok, I think I had a good idea to solve my problem and need someone who second me on that or tell me what a fool I am :-) . My problem: I went for curve-fitting with nls() and took knot()-ecdf() for collecting data for nls-basis-dataframe. I came into trouble, because my x-y-data of the

  1   2   >