Re: [R] EDCR build from source with namespace problem

2013-04-22 Thread Tito de Morais Luis
Thank you very much Roy. I will the wait Luis Tito Le 19/04/2013 15:48, Roy Mendelssohn - NOAA Federal a écrit : Several changes in R and in Java broke the code in EDCR. We have in beta a new version that fixes these problems. I will be certain to let you know when it is ready. -Roy M.

Re: [R] how to import several files every day

2013-04-22 Thread Jim Lemon
On 04/22/2013 10:14 AM, Martin Lavoie wrote: Hi Jim thanks for the help. I think I understand all the steps you suggested. I tried an example with your code but there is something not working I think. See below. all.filenames-list.files(__path=pathtofile, full.names=TRUE) /#this step works/

Re: [R] extracting the diagonal of an inverse matrix

2013-04-22 Thread Camarda, Carlo Giovanni
Dear Greg, thanks a lot for your prompt reply. I was aware of the link and the associated papers. In my previous mail I was wondering whether there was already an R-routine for coping with this issue. I add below a testable example which reproduces my problem. Thanks again, Giancarlo ##

Re: [R] How to set frequncy?

2013-04-22 Thread Rui Barradas
Hello, If stock prices are daily data, use frequency = 1. Hope this helps, Rui Barradas Em 21-04-2013 14:22, Lizhu Ren escreveu: Hi Boss, i have data of one stock price from 2 January 2006 to 31 December 2012.But each year had different markert day, I want to calculate daily returns and

Re: [R] R CMD build

2013-04-22 Thread Knut Krueger
Am 21.04.2013 04:14, schrieb Henrik Bengtsson: FYI, R CMD build ... works just fine on Windows (and I'm sure R cmd build ... won't). /Henrik Yes it works, unfortunately windows user need not consider capitals or not. When sitting on a Windows PC I usually typing lower cas only on Linux I am

Re: [R] R CMD build

2013-04-22 Thread Knut Krueger
Am 21.04.2013 04:59, schrieb Gabor Grothendieck: That is correct but if one were using the batchfiles I mentioned then both work. -- Statistics Batch files? I can find only xls2csv.bat and RunSnowWorker.bat in the 3.0 directories. Knut __

Re: [R] cluster gene list

2013-04-22 Thread Catarina Maia
Hello, I'm just a beginner and probably there is a better way to do it but here it goes: #cluster analysis Euclidean_Distance - dist(mydata, method=euclidean, diag=FALSE , upper=FALSE, p=2) data - hclust(Euclidean_Distance, method=ward, members=NULL) plot(data,hang=-1) #K=4 # i chose to

[R] question

2013-04-22 Thread nafiseh hagiaghamohammadi
Hi Does anyone know if there is a method to calculate a goodness-of-fit statistic for quantile regressions with package quantreg? Tanks [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

[R] Rattle for R-3.0.0?

2013-04-22 Thread Казахстанский филиал МГУ им . Ломоносова
To Whom It May Concern, When trying to install Rattle for R-3.0.0 we get a message package ‘rattle’ is not available (for R version 2.14.1) The same message we get when we try to install Rattle for earlier versions of R. Would you be so kind to let us know how to overcome the problem? Many

[R] Plot fail with dbscan (package fpc) and dataset with only noise

2013-04-22 Thread Forconi
Hi, I'm using the clustering package 'fpc' to make some test with the dbscan algorithm. The commands I'm using are rather simple: csvdata - read.table(C:/file.csv, header = TRUE) dataset - csvdata[,c('D1', 'D2', 'D3', 'D4', 'D5', 'D6', 'D7')] ds - dbscan(dataset, 0.15, MinPts = 10)

Re: [R] how to import several files every day

2013-04-22 Thread Martin Lavoie
Hi Jim actually I did not underscore my code. I just copied and pasted the original code you suggested. but here is what I have on my system (I tried with csv files if I would get a different result): # setwd(~/Desktop/folder/) system(echo xxx old.filenames.tab)

Re: [R] how to import several files every day

2013-04-22 Thread Jim Lemon
On 04/22/2013 09:00 PM, Martin Lavoie wrote: Hi Jim actually I did not underscore my code. I just copied and pasted the original code you suggested. but here is what I have on my system (I tried with csv files if I would get a different result): # setwd(~/Desktop/folder/) system(echo xxx

Re: [R] Rattle for R-3.0.0?

2013-04-22 Thread Duncan Murdoch
On 13-04-22 2:18 AM, Казахстанский филиал МГУ им.Ломоносова wrote: To Whom It May Concern, When trying to install Rattle for R-3.0.0 we get a message package ‘rattle’ is not available (for R version 2.14.1) It is available for R 3.0.0. It looks like you were running 2.14.1 when you tried to

Re: [R] How to set frequncy?

2013-04-22 Thread R. Michael Weylandt
On Mon, Apr 22, 2013 at 9:54 AM, Rui Barradas ruipbarra...@sapo.pt wrote: Hello, If stock prices are daily data, use frequency = 1. Err, maybe... The frequency attribute for a ts class time series is somewhat subtle. It's the amount of observations per seasonal period / relevant cycle, where

Re: [R] How to set frequncy?

2013-04-22 Thread Rui Barradas
Hello, You've not Cc'ed the list If you keep the discussion on the list, you'll have more and better answers. See the post by Michael Weylandt for a more complete answer to your question. Rui Barradas Em 22-04-2013 12:16, Lizhu Ren escreveu: thanks for u replying, i think in setting

Re: [R] question

2013-04-22 Thread Roger Koenker
In quantreg if you do FAQ() item 4 is: 4. [R^2] I am currently trying to caculate the coefficient of determination for different quantile regression models. For example, how do you calculate the the sum of the weighted absolute deviations in the models ... R-squared is evil,

[R] Multiple lon lat points in the map with ggplot2

2013-04-22 Thread Simonas Kecorius
Hello R users, For the last few days I am struggling with the following task: my data.frame: A1A2A3 B1 B2 B3 58.81 53.292 54.501 13.013 17.39 19.407 56.02 56.251 54.033 20.099 13.15 10.411 55.376 53.099 57.625 13.396 21.031

[R] numerical integration of a bivariate function

2013-04-22 Thread Hicham Mezouara
hello I work on the probabilities of bivariate normal distribution. I need integrate  the following function. f (x, y) = exp [- (x ^ 2 + y ^ 2 + x * y)] with - ∞ ≤ x ≤ 7.44 and - ∞ ≤ y ≤ 1.44   , either software R or  matlab Version R 2009a Thank you for helping me Regards

Re: [R] numerical integration of a bivariate function

2013-04-22 Thread R. Michael Weylandt
On Mon, Apr 22, 2013 at 2:04 PM, Hicham Mezouara hicham_d...@yahoo.fr wrote: hello I work on the probabilities of bivariate normal distribution. I need integrate the following function. f (x, y) = exp [- (x ^ 2 + y ^ 2 + x * y)] with - ∞ ≤ x ≤ 7.44 and - ∞ ≤ y ≤ 1.44 , either software R

[R] Hmisc pdflatex

2013-04-22 Thread Santosh
Dear Rxperts, Apologize for posting it to a wrong thread..Hence, the re-post... I am trying to use pdflatex from Hmisc, I get the error message. pdflatex is not available... The version of Hmisc is the latest one (got the warning that it was compiled under R version 2.15.3) . The version of R on

Re: [R] Hmisc pdflatex

2013-04-22 Thread Duncan Murdoch
On 22/04/2013 10:34 AM, Santosh wrote: Dear Rxperts, Apologize for posting it to a wrong thread..Hence, the re-post... I am trying to use pdflatex from Hmisc, I get the error message. pdflatex is not available... The version of Hmisc is the latest one (got the warning that it was compiled under

[R] Sensitivity Analysis

2013-04-22 Thread Gilson Carvalho
Hi all, Do nnet, neuralnet or RSNNS implemented any kind of sensitivity analysis? Best Wishes, -- Prof. Gilson Correia de Carvalho, M.Sc. Pesquisador Associado Laboratório de Ecologia Bentônica - LEB Instituto de Biologia - UFBA Universidade

[R] Scatterplot and Causality

2013-04-22 Thread Lorenzo Isella
Dear All, I hope this is not too off topic. I am given a set of scatteplots (nothing too fancy; think about a normal x-y 2D plot). I do not deal with two time series (indeed I have no info about time). If I call A=(A1,A2,...) and B=(B1, B2, ...) the 2 variables (two vectors of numbers most of the

Re: [R] numerical integration of a bivariate function

2013-04-22 Thread Berend Hasselman
On 22-04-2013, at 15:04, Hicham Mezouara hicham_d...@yahoo.fr wrote: hello I work on the probabilities of bivariate normal distribution. I need integrate the following function. f (x, y) = exp [- (x ^ 2 + y ^ 2 + x * y)] with - ∞ ≤ x ≤ 7.44 and - ∞ ≤ y ≤ 1.44 , either software R or

Re: [R] Scatterplot and Causality

2013-04-22 Thread Duncan Murdoch
On 22/04/2013 10:48 AM, Lorenzo Isella wrote: Dear All, I hope this is not too off topic. I am given a set of scatteplots (nothing too fancy; think about a normal x-y 2D plot). I do not deal with two time series (indeed I have no info about time). If I call A=(A1,A2,...) and B=(B1, B2, ...) the

Re: [R] Scatterplot and Causality

2013-04-22 Thread R. Michael Weylandt
On Mon, Apr 22, 2013 at 3:48 PM, Lorenzo Isella lorenzo.ise...@gmail.com wrote: Dear All, I hope this is not too off topic. I am given a set of scatteplots (nothing too fancy; think about a normal x-y 2D plot). I do not deal with two time series (indeed I have no info about time). If I call

Re: [R] Scatterplot and Causality

2013-04-22 Thread Robert Baer
On 4/22/2013 9:48 AM, Lorenzo Isella wrote: Dear All, I hope this is not too off topic. I am given a set of scatteplots (nothing too fancy; think about a normal x-y 2D plot). I do not deal with two time series (indeed I have no info about time). If I call A=(A1,A2,...) and B=(B1, B2, ...) the 2

Re: [R] extracting the diagonal of an inverse matrix

2013-04-22 Thread William Dunlap
You could save the space required to store the inverse of A by repeating solve(A,column) for each column of an identity matrix the size of A, and store just the relevant element of the result. E.g., diag(solve(A)) [1] 0.39576620 0.12064108 0.20705171 0.10067892 0.03191425 0.05857497

Re: [R] odfWeave: Some questions about potential formatting options

2013-04-22 Thread Paul Miller
Hi Milan and Max,   Thanks for your most recent replies. I wasn't able to sucessfully implement any of your proposed solutions, but am not overly worried about it. For example, I found that I could not get the Greek letter chi into my table footnotes via odfCat using unicode or escape codes (I

Re: [R] Sensitivity Analysis

2013-04-22 Thread Gilson Carvalho
Hi all, Do nnet, neuralnet or RSNNS implemented any kind of sensitivity analysis? Best Wishes, Em 22 de abril de 2013 11:46, Gilson Carvalho biogil...@gmail.comescreveu: Hi all, Do nnet, neuralnet or RSNNS implemented any kind of sensitivity analysis? Best Wishes, -- Prof. Gilson

Re: [R] Reshape or Plyr?

2013-04-22 Thread Law, Jason
Hi Bruce, I work with a lot of similar data and have to do these types of things quite often. I find it helps to keep to vectorized code as much as possible. That is, do as many of the calculations as possible outside of the aggregation code. Here's one way: library(reshape2) # stick to a

Re: [R] how to import several files every day

2013-04-22 Thread Greg Snow
Jim Lemon showed one option of keeping a list of the files that have already been processed and comparing to this list to see which files are new. Here are a couple of other possibilities: You could move a file from the input folder to an archive folder after processing it (file.rename or system

Re: [R] More

2013-04-22 Thread arun
Hi Bruce, From your excel sheets, it looks like for the step1, you were just taking only the Survey Time of the first rows of unique Start_Day for each Location_name. Step2 results looks the same as res2 If this is the case: dat1-

Re: [R] More

2013-04-22 Thread arun
Hi Bruce, This could be also done by: dat1- read.csv(Sample_all_3_locations.csv,header=TRUE,stringsAsFactors=FALSE,sep=,) library(plyr) res1-ddply(unique(dat1[,c(1,3:4)]),.(Location_name),summarize,Survey_Time=sum(Survey_Time)) #changed here res1 #  Location_name Survey_Time #1

[R] ggplot-display text in bar chart

2013-04-22 Thread Ye Lin
I want to show counts value on stacked bar chart in ggplot2. I found similar question here http://stackoverflow.com/questions/6644997/showing-data-values-on-stacked-bar-chart-in-ggplot2 but that one shows value instead of counts. My data frame(dat1) is sth like this: Group Length Width 1

Re: [R] Scatterplot and Causality

2013-04-22 Thread Lorenzo Isella
On Mon, 22 Apr 2013 17:27:05 +0200, Robert Baer rb...@atsu.edu wrote: It strikes me that this is not a particularly productive approach to causality, particularly in an observational setting. You would need to design an experiment where you had a known manipulation of an explanatory

Re: [R] Hmisc pdflatex

2013-04-22 Thread Santosh
Dear expeRts! Thanks for suggestions about getting MiKTeX... I have that installed.. The Sys.getenv(PATH) also reflects the path of pdflatex.. I noticed that the function creates .dvi, .aux files in the current working directory but looks for these files in Sys.getenv(TEMP) folder. Is there away

Re: [R] Scatterplot and Causality

2013-04-22 Thread Bert Gunter
Inline. On Mon, Apr 22, 2013 at 1:15 PM, Lorenzo Isella lorenzo.ise...@gmail.com wrote: On Mon, 22 Apr 2013 17:27:05 +0200, Robert Baer rb...@atsu.edu wrote: It strikes me that this is not a particularly productive approach to causality, particularly in an observational setting. You would

[R] RODBC --How do you set up the connection so pwd is blank but driver-specific data source dialog box pops up after

2013-04-22 Thread Lopez, Dan
Hello, I want to leave pwd blank (to comply w/ company security protocol) and just be prompted by the driver-specific data source dialog box to enter the password after. But for some reason it is not working. R Version: R version 2.15.1 (2012-06-22) R Studio Version: 0.97.312 OS: Windows 7

Re: [R] Scatterplot and Causality

2013-04-22 Thread Joerg Luedicke
Nevertheless, some people try: http://www.kaggle.com/c/cause-effect-pairs Joerg On Mon, Apr 22, 2013 at 4:31 PM, Bert Gunter gunter.ber...@gene.com wrote: Inline. On Mon, Apr 22, 2013 at 1:15 PM, Lorenzo Isella lorenzo.ise...@gmail.com wrote: On Mon, 22 Apr 2013 17:27:05 +0200, Robert

Re: [R] RODBC --How do you set up the connection so pwd is blank but driver-specific data source dialog box pops up after

2013-04-22 Thread Lopez, Dan
Daniel, Thanks for letting me know. I'll try it w/o Rstudio if needed. Thanks. Dan -Original Message- From: Daniel J. Robertson [mailto:dj...@cornell.edu] Sent: Monday, April 22, 2013 1:51 PM To: Lopez, Dan; R help (r-help@r-project.org) Subject: RE: [R] RODBC --How do you set up the

[R] R not loading

2013-04-22 Thread Barbour, Russell
I am having a problem with loading R on my 64 bit computer. It used to load perfectly until I upgraded to R 3.0.0 now it takes about 10 to even 20 minutes ? Does anyone know how to remedy this problem? Russell Skip Barbour Ph.D. Associate Director for Statistics Center for

Re: [R] Print occurrence / positions of words

2013-04-22 Thread arun
Hi, May be this helps: vec- this is a nice text with nice characters library(stringr)  vec2-unlist(str_match_all(vec,\\w+)) #or # vec2-str_split(vec, )[[1]] res-unique(lapply(vec2,function(x) which(!is.na(match(vec2,x)  names(res)- unique(vec2) res #$this #[1] 1 # #$is #[1] 2 # #$a #[1] 3 #

Re: [R] RODBC --How do you set up the connection so pwd is blank but driver-specific data source dialog box pops up after

2013-04-22 Thread Daniel J. Robertson
The password window popup apparently doesn't yet work with RStudio: e.g., http://support.rstudio.org/help/discussions/problems/4371-rodbc-connection-issue -- Daniel Robertson Senior Research and Planning Associate Institutional Research and Planning Cornell University / irp.cornell.edu

[R] Copula fitMdvc:

2013-04-22 Thread Elisa Taveras Pena
Hello, I am trying to do a fit a loglikelihood function with Multivariate distribution via copulas with fitMdvc. The problem is that it doesn't recognize that my beta is a vector of km parameter and when I try to run it it say that the length of my initial values is not the same as the

[R] subset dataframe

2013-04-22 Thread Mihai Nica
I can't understand what is happening. This is the code and results:  agoa - read.table(file = C:/Users/HTPC/Documents/_Documents/Research/WithDidia/AGOAUSImports.txt, header = T, sep = \t, dec = ., na.strings = NA, stringsAsFactors = T)# str(agoa); names(agoa) 'data.frame':109 obs. of  

Re: [R] subset dataframe

2013-04-22 Thread Jorge I Velez
Mike, You need subset(agoa, agoa$X.1 == AGOA ) instead of subset(agoa, agoa$X.1 == AGOA) (note the space after the last A in AGOA. HTH, Jorge.- On Tue, Apr 23, 2013 at 7:14 AM, Mihai Nica mihain...@yahoo.com wrote: I can't understand what is happening. This is the code and results:

Re: [R] Scatterplot and Causality

2013-04-22 Thread Rolf Turner
Fortune nomination. cheers, Rolf On 23/04/13 08:31, Bert Gunter wrote: (In response to a question about inferring causality from observational data.) As others have said: (Short answer) No. (Long Answer) Don't be ridiculous.

Re: [R] Scatterplot and Causality

2013-04-22 Thread Belmont, John W
See bayes.cs.ucla.edu/jp_home.html for interesting insights -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Rolf Turner Sent: Monday, April 22, 2013 4:52 PM To: Bert Gunter Cc: r-h...@stat.math.ethz.ch; Achim Zeileis Subject:

Re: [R] R not loading

2013-04-22 Thread Michael Weylandt
On Apr 22, 2013, at 21:15, Barbour, Russell russell.barb...@yale.edu wrote: I am having a problem with loading R on my 64 bit computer. It used to load perfectly until I upgraded to R 3.0.0 now it takes about 10 to even 20 minutes ? Does anyone know how to remedy this problem?

Re: [R] R not loading

2013-04-22 Thread Peter Langfelder
On Mon, Apr 22, 2013 at 1:15 PM, Barbour, Russell russell.barb...@yale.edu wrote: I am having a problem with loading R on my 64 bit computer. It used to load perfectly until I upgraded to R 3.0.0 now it takes about 10 to even 20 minutes ? Does anyone know how to remedy this problem?

Re: [R] subset dataframe

2013-04-22 Thread arun
HI, Could you provide an example dataset? set.seed(15) agoa- data.frame(X.1=rep(c(AGOA,GSP,CST),3),X1996= sample(1:2,9,replace=TRUE),X2000=sample(40:3,9,replace=TRUE))  str(agoa) #'data.frame':    9 obs. of  3 variables: # $ X.1  : Factor w/ 3 levels AGOA,CST,GSP: 1 3 2 1 3 2 1 3 2 # $

Re: [R] subset dataframe

2013-04-22 Thread arun
Hi, Just noticed that there is a space after Angola $ X    : Factor w/ 39 levels Angola , If that is the case: set.seed(15)  agoa- data.frame(X.1=rep(c(AGOA ,GSP,CST),3),X1996= sample(1:2,9,replace=TRUE),X2000=sample(40:3,9,replace=TRUE))   subset(agoa,X.1==AGOA) #[1] X.1   X1996 X2000

[R] Vector with zeros and ones

2013-04-22 Thread Ayyappa
Dear group, I want to generate a vector of 10 elements that always has 20% zeroes, but with a random ordering of zeroes and ones. Can you please suggest a function to do that in R? I tried 'sample' function but the 20% zeros was not always guaranteed. Thanks for your help. Regards, Ayyappa

Re: [R] Vector with zeros and ones

2013-04-22 Thread R. Michael Weylandt
On Mon, Apr 22, 2013 at 7:21 PM, Ayyappa ayyapp...@gmail.com wrote: Dear group, I want to generate a vector of 10 elements that always has 20% zeroes, but with a random ordering of zeroes and ones. Can you please suggest a function to do that in R? I tried 'sample' function but the 20%

Re: [R] Vector with zeros and ones

2013-04-22 Thread Marc Schwartz
On Apr 22, 2013, at 6:21 PM, Ayyappa ayyapp...@gmail.com wrote: Dear group, I want to generate a vector of 10 elements that always has 20% zeroes, but with a random ordering of zeroes and ones. Can you please suggest a function to do that in R? I tried 'sample' function but the 20% zeros

Re: [R] Vector with zeros and ones

2013-04-22 Thread Marc Schwartz
On Apr 22, 2013, at 6:28 PM, Marc Schwartz marc_schwa...@me.com wrote: On Apr 22, 2013, at 6:21 PM, Ayyappa ayyapp...@gmail.com wrote: Dear group, I want to generate a vector of 10 elements that always has 20% zeroes, but with a random ordering of zeroes and ones. Can you please suggest

Re: [R] subset dataframe

2013-04-22 Thread Mihai Nica
Thanks Arun, Jorge,s idea worked... I can't believe I lost so much time with this...   mike From:arun smartpink...@yahoo.com To: Mihai Nica mihain...@yahoo.com Cc: R help r-help@r-project.org Sent: Monday, April 22, 2013 4:57 PM Subject:Re: [R] subset

Re: [R] Hmisc pdflatex

2013-04-22 Thread Santosh
Dear Rxperts.. The problem of latex looking for tex and dvi files in a TEMP folder still persists. As a work around, I changed the options.. options(latexcmd=pdflatex,dviExtension=pdf) After the above change, latex(,file=a1) seems to work but the resulting pdf file is something

[R] Tables package - remove NAs and NaN

2013-04-22 Thread Santosh
Dear Rxperts, q - data.frame(p=rep(c(A,B),each=10,len=30), a=rep(c(1,2,3),each=10),id=seq(30), b=round(runif(30,10,20)), c=round(runif(30,40,70))) The operation below... tabular(((p=factor(p))*(a=factor(a))+1) ~ (N = 1) + (b + c)* (mean+sd),data=q) yields some rows of NAs and NaN as shown below

[R] Meijer G-function

2013-04-22 Thread Sachinthaka Abeywardana
Hi All, Does anyone know if there is an implementation of the G-function in R. If so please let me know (could not find this on google). Thanks, Sachin [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] Tables package - remove NAs and NaN

2013-04-22 Thread David Winsemius
On Apr 22, 2013, at 5:49 PM, Santosh wrote: Dear Rxperts, q - data.frame(p=rep(c(A,B),each=10,len=30), a=rep(c(1,2,3),each=10),id=seq(30), b=round(runif(30,10,20)), c=round(runif(30,40,70))) The operation below... tabular(((p=factor(p))*(a=factor(a))+1) ~ (N = 1) + (b + c)*

[R] Frustration to get help R users group

2013-04-22 Thread Champak Ishram
Dear R users/developers I requested help to solve the problem of formulating Multivariate Sample selection model by using Full Information Maximum Likelihood (FIML)estimation method. I could not get any response. I formulated the following code of FIML to analyse univariate sample selection

Re: [R] Frustration to get help R users group

2013-04-22 Thread Jeff Newmiller
This is dangerously close to a statistics theory question, which would be off-topic on this list. In any event, your example is definitely not reproducible (no sample data) [1]. Now might also be a good opportunity for you to read the Posting Guide mentioned at the bottom of every message on

Re: [R] Hmisc pdflatex

2013-04-22 Thread Duncan Mackay
Hi I have come late to the discussion how about trying ? texi2dvi for pdf or dvi eg texi2dvi(D:/Cic/Sweave/Figs/Sheep3/FS/15/sFSheepFS15.tex, pdf = TRUE, clean = TRUE) Version R version 3.0.0 (2013-04-03), i386-w64-mingw32 Win 7 I made an environmental variable for Miktex in Windows or it