Re: [R] asking for large memory - crash running rterm.exe on windows

2016-05-28 Thread Anthony Damico
hi, thanks to you both! note the large memory.limit() on the machine before the crash (200+ gb) so i'm not sure it's a simple overloading explosion? i've filed a bug report.. https://bugs.r-project.org/bugzilla/show_bug.cgi?id=16927 On Saturday, May 28, 2016, Martin Maechler

Re: [R] Creating R file

2016-05-28 Thread Hong Yu
You are right, that it is unnecessary to relate to excel. I explain this way, because I often tutor people with little programming experience, and often I tutor people with no concept of “text editors”. From: Rolf Turner Sent: Sunday, May 29, 2016 5:57 AM To: Hong Yu Cc:

Re: [R] read multiple sheets of excel data into R

2016-05-28 Thread jim holtman
Try the 'openxlsx' package. I gave up using XLConnect because of the Java requirement, and speed on larger tables. "openxlsx" has the access routines written in C so you don't need any other outside dependencies. Jim Holtman Data Munger Guru What is the problem that you are trying to solve?

Re: [R] Creating R file

2016-05-28 Thread Rolf Turner
On 28/05/16 19:37, Hong Yu wrote: When you need numerical data input in R programs, you can use EXCEL to create .csv file. When you need output calculation results, you can write out .csv file in R programs. Yes, the most common .cvs file format is comma seperated numerical values. You

Re: [R] Application of "merge" and "within"

2016-05-28 Thread Duncan Murdoch
On 27/05/2016 7:00 PM, Santosh wrote: Dear Rxperts! Is there a way to compute relative values.. using within().. function? Any assistance/suggestions are highly welcome!! Thanks again, Santosh... ___ A sample dataset and the

Re: [R] Application of "merge" and "within"

2016-05-28 Thread Jeff Newmiller
Why do you want to do this? -- Sent from my phone. Please excuse my brevity. On May 27, 2016 4:00:14 PM PDT, Santosh wrote: >Dear Rxperts! > >Is there a way to compute relative values.. using within().. function? > >Any assistance/suggestions are highly welcome!! >Thanks

Re: [R] Trimming time series to only include complete years

2016-05-28 Thread Jeff Newmiller
# read about POSIXlt at ?DateTimeClasses # note that the "mon" element is 0-11 isPartialWaterYear <- function( d ) { dtl <- as.POSIXlt( dat$Date ) wy1 <- cumsum( ( 9 == dtl$mon ) & ( 1 == dtl$mday ) ) ( 0 == wy1 # first partial year | ( 8 != dtl$mon[ nrow( dat ) ] # end partial year

Re: [R] sandwich package: HAC estimators

2016-05-28 Thread Achim Zeileis
On Sat, 28 May 2016, T.Riedle wrote: Dear R users, I am running a logistic regression using the rms package and the code looks as follows: crisis_bubble4<-lrm(stock.market.crash~crash.MA+bubble.MA+MP.MA+UTS.MA+UPR.MA+PPI.MA+RV.MA,data=Data_logitregression_movingaverage) Now, I would like

Re: [R] read multiple sheets of excel data into R

2016-05-28 Thread Jeff Newmiller
Apparently you need to get your Java runtime setup, or install Perl, depending which of these tools you want to use. Or if your data are laid out simply, you might be able to use the readxl package. -- Sent from my phone. Please excuse my brevity. On May 28, 2016 10:55:50 AM PDT, li li

[R-es] Omitir Na en Forecast.Arima

2016-05-28 Thread Elkin Tabares
Hola a toda la comunidad R, Tengo un error al tratar de realizar un pornóstico usando un modelo armax, aunque tengo pronóstico para mis variables exógenas, algunas de estas estan rezagadas, por tanto contienen datos NA, obteniendo el siguiente error: Error in quantile.default(newX[, i], ...) :

[R] read multiple sheets of excel data into R

2016-05-28 Thread li li
Hi all, I tried to use the package "XLConnect" to read excel data into R. I got the following error message: Error : .onLoad failed in loadNamespace() for 'rJava', details: call: fun(libname, pkgname) error: No CurrentVersion entry in Software/JavaSoft registry! Try re-installing Java and

Re: [R] read.fortran format

2016-05-28 Thread William Dunlap via R-help
>The bit about the decimal leading to a shift in the decimal place >pointed out by Bill is a bit obscure, though it to is mentioned in the help file. I don't think that is how real Fortran formats work. My memory is that you only put a dot in the format if there were no dots in your data file

[R] sandwich package: HAC estimators

2016-05-28 Thread T.Riedle
Dear R users, I am running a logistic regression using the rms package and the code looks as follows: crisis_bubble4<-lrm(stock.market.crash~crash.MA+bubble.MA+MP.MA+UTS.MA+UPR.MA+PPI.MA+RV.MA,data=Data_logitregression_movingaverage) Now, I would like to calculate HAC robust standard errors

Re: [R-es] Última (más reciente) posición de un vector (con "n" desconocido)

2016-05-28 Thread Jorge I Velez
Hola Gemma, Intenta x[length(x)] tail(x, 1) Saludos, Jorge.- 2016-05-28 11:52 GMT-05:00 Gemma Ruiz-Olalla : > Hola, > > Hay alguna forma de acceder a la última posición de un vector si se > desconoce "n"? (por estar dentro de un bucle "for" que va incrementando

[R-es] Última (más reciente) posición de un vector (con "n" desconocido)

2016-05-28 Thread Gemma Ruiz-Olalla
Hola, Hay alguna forma de acceder a la última posición de un vector si se desconoce "n"? (por estar dentro de un bucle "for" que va incrementando su contador) La idea es acceder al valor de vector[n] en el caso de que "n" sea una incógnita. Estoy casi segura de que es posible pero mi

Re: [R] Getting Rid of NaN in ts Object

2016-05-28 Thread Martin Maechler
> Perfect! > Exactly what I was looking for. > Thanks > Lorenzo > On Fri, May 27, 2016 at 01:50:03PM +0200, Christian Brandstätter wrote: >> Hi Lorenzo, >> >> Try: >> >> tt[is.nan(tt)] <- NA >> tt <- na.omit(tt) >> or simply na.omit(tt) as it omits both NA and NaN (and *does* keep the

Re: [R] asking for large memory - crash running rterm.exe on windows

2016-05-28 Thread Martin Maechler
> Ben Bolker > on Sat, 28 May 2016 15:42:45 + writes: > Anthony Damico gmail.com> writes: >> >> hi, here's a minimal reproducible example that crashes my >> R 3.3.0 console on a powerful windows server. below the >> example, i've put the

Re: [R] colored table

2016-05-28 Thread Duncan Murdoch
On 28/05/2016 9:10 AM, Naresh Gurbuxani wrote: I want to print a table where table elements are colored according to the frequency of the bin. For example, consider below table. How to do this depends on how you want to print the result. Are you looking for a LaTeX table, HTML, Word, or

Re: [R] code to provoke a crash running rterm.exe on windows

2016-05-28 Thread Ben Bolker
Anthony Damico gmail.com> writes: > > hi, here's a minimal reproducible example that crashes my R 3.3.0 console > on a powerful windows server. below the example, i've put the error (not > crash) that occurs on R 3.2.3. > > should this be reported to http://bugs.r-project.org/ or am i doing >

Re: [R] colored table

2016-05-28 Thread Jeff Newmiller
If you don't mix the text and color, heatmaps are pretty standard presentation techniques. -- Sent from my phone. Please excuse my brevity. On May 28, 2016 7:41:53 AM PDT, Bert Gunter wrote: >Hi Naresh: > >I shall be brief, as discussions of what statistical/graphical

Re: [R] colored table

2016-05-28 Thread Bert Gunter
Hi Naresh: I shall be brief, as discussions of what statistical/graphical techniques to use are largely OT. IMO, this is a bad idea. I think the table entries will be very difficult to read and groc. If the tables are unrelated, use 2 tables. If you think they might be related, plot the entries

[R] code to provoke a crash running rterm.exe on windows

2016-05-28 Thread Anthony Damico
hi, here's a minimal reproducible example that crashes my R 3.3.0 console on a powerful windows server. below the example, i've put the error (not crash) that occurs on R 3.2.3. should this be reported to http://bugs.r-project.org/ or am i doing something silly? thanx #

Re: [R] Creating R file

2016-05-28 Thread Jeff Newmiller
This sounds like homework, which has been determined to be off-topic on this help list. Please read the Posting Guide before posting. That said, it would appear the OP may need to read about data frames in, say, the Introduction to R... and perhaps about matrices... and using the as.*

Re: [R] Creating R file

2016-05-28 Thread Hong Yu
When you need numerical data input in R programs, you can use EXCEL to create .csv file. When you need output calculation results, you can write out .csv file in R programs. Yes, the most common .cvs file format is comma seperated numerical values. You can use EXCEL to create .csv file, and

Re: [R] Creating R file

2016-05-28 Thread David Winsemius
> On May 27, 2016, at 4:40 PM, jay28 via R-help wrote: > > Hi. I am new to R and confused by some conflicting and contradictory > information about it. Where and how do I create a numeric data file with .csv > extension for use in R? So numbers meaning numeric data will

[R] Creating R file

2016-05-28 Thread jay28 via R-help
 Hi. I am new to R and confused by some conflicting and contradictory information about it. Where and how do I create a numeric data file with .csv extension for use in R? So numbers meaning numeric data will be separated by commas and will consist of one line of numbers randomly chosen from 1