Re: [R] A simple string alienation problem

2020-04-14 Thread PIKAL Petr
Hi attachement did not went through, only limited attachement types are allowed - see Posting guide. I am not sure if R is the best possibility to remove some characters. If " is at the end of all your strings > dput(test) structure(list(V1 = c("adfvadfg\"", "sdfasd\"", "vafdv\"", "hjk/tiuk\""

Re: [R] Package renv and Rscript

2020-04-14 Thread Ben Tupper
Hi, Ah, of course - the wrapper would be a shell wrapper not an R wrapper ... ### #!/bin/sh cd /path/to/project Rscript /path/to/script.R /path/to/config_file ### Thanks so much! Ben On Tue, Apr 14, 2020 at 2:13 PM Thierry Onkelinx wrote: > Dear Ben, > > I think that you first need to go to y

[R] Span for loess regression

2020-04-14 Thread varin sacha via R-help
Dear R-experts, I am trying to find the best span for my loess regression. Here below a reproducible example. I don't get the result. Am I missing something ? Many thanks for your help. a<-c(2,3,4,3,2,6,5,7,4,5,12,13,21,6,4,5,6,7) b<-

Re: [R] Difference in offset values in R and STATA

2020-04-14 Thread Patrick (Malone Quantitative)
Also, is the default base for "log" the same in both programs? On Tue, Apr 14, 2020 at 3:36 PM Sorkin, John wrote: > > Your question is unlikely to be answered unless you post code demonstrating > the problem > J > > John David Sorkin M.D., Ph.D. > Professor of Medicine > Chief, Biostatistics a

Re: [R] Difference in offset values in R and STATA

2020-04-14 Thread Sorkin, John
Your question is unlikely to be answered unless you post code demonstrating the problem J John David Sorkin M.D., Ph.D. Professor of Medicine Chief, Biostatistics and Informatics University of Maryland School of Medicine Division of Gerontology and Geriatric Medicine Baltimore VA Medical Center

[R] Difference in offset values in R and STATA

2020-04-14 Thread Haddison Mureithi
Hae guys, When performing a poisson regression sometimes one has to input the offset/exposure variable to account for individual time spent in a certain therapy before acquiring a certain condition of interest, whereby in r offset(log(months)) and in STATA offset(log(months)) results differ. Thereb

Re: [R] Package renv and Rscript

2020-04-14 Thread Thierry Onkelinx via R-help
Dear Ben, I think that you first need to go to your project and then start Rscript from that location. renv() needs to pick up the .Renviron file located at the root of your project. Best regards, ir. Thierry Onkelinx Statisticus / Statistician Vlaamse Overheid / Government of Flanders INSTITUU

Re: [R] spatstat installation

2020-04-14 Thread Bert Gunter
If you don't receive a satisfactory answer here in a day or so, post on the R-sig-geo list where the experts in this sort of thing hang around. Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Brea

Re: [R] Package renv and Rscript

2020-04-14 Thread Ben Tupper
Whoops! The silly "send" button jumped out and grabbed my cursor before I was ready for it. Second try... I am using renv (https://rstudio.github.io/renv/) to maintain a project environment in a directory (ala '/path/to/project'). Within the project I have a number of scripts that I call with o

[R] Package renv and Rscript

2020-04-14 Thread Ben Tupper
Hi, I am using renv (https://rstudio.github.io/renv/) to maintain a project environment in a directory (ala /path/to/project) Within the project I have a number of scripts that I call using... $ Rscript /path/to/script.R /path/to/config_file I can kick this off successfully with the renv envir

Re: [R] A simple string alienation question.

2020-04-14 Thread Erich Subscriptions
read.csv has parameters sep, quote and dec You have to get these right to represent the structure of you input file. > On 14.04.2020, at 11:28, Sam Charya via R-help wrote: > > > > Hello Dear R Community, > I would ask a little bit of help from you please:I have a dataset, which is > in a CSV

[R] spatstat installation

2020-04-14 Thread Mauro Pedone
Hello , I am trying the spatstat package installation on R 3.3.0 the package is spatstat_1.63-3.tar.gz ,the OS is oracle enterprise linux 7 at the end I receive the error Error : .onAttach failed in attachNamespace() for 'spatstat', details: call: if (today - as.Date(rdate) > 365) { error: mi

[R] A simple string alienation problem

2020-04-14 Thread Soumyadip Bhattacharyya
***Dear Eric,* sending from gmail following the way you suggested. Hope now everyone can see this email. I have also attached the first 50 rows of the FIght.csv.*** ***Output - I will try to do Market basket analysis on this to find out rules that I am learning. so once I have the data in

Re: [R] A simple string alienation problem

2020-04-14 Thread Eric Berger
Hi Sam, My code below adds new columns to your data frame so you have the original columns in order to compare. (Also this could help in case there are a few rows that don't work in the full set.) > x <- read.csv("Fight.csv", stringsAsFactors = F, header = F) > x$V3 <- sub("\\\"","",x$V1) # remo

Re: [R] A simple string alienation question.

2020-04-14 Thread Eric Berger
Hi Sam, This should be straightforward. But to help out the people who could give you an answer it would be better if you could provide the information a bit more clearly as follows: 1. send your email in plain text mode. If you use gmail, when you are composing your email, you can click on the 3 d

Re: [R] Error with devTools

2020-04-14 Thread Eric Berger
RStudio provides a terminal window. You could print out the environment variables there and then adjust the ones in your R console session appropriately. I could give you some guidance under linux, but it seems you use Windows. Perhaps others can help with the details. On Tue, Apr 14, 2020 at 12:1

[R] A simple string alienation question.

2020-04-14 Thread Sam Charya via R-help
Hello Dear R Community, I would ask a little bit of help from you please:I have a dataset, which is in a CSV file – I have read it into R as follows:                   V11   tropical fruit"2       whole milk"3        pip fruit"4 other vegetables"5       whole milk"6       rolls/buns" The issue

Re: [R] Error with devTools

2020-04-14 Thread Duncan Murdoch
No, I mean the path to the other Rtools. I think the only solution to avoid the quiet = TRUE is to modify the devtools package, or don't use it. Duncan Murdoch On 14/04/2020 4:18 a.m., iurii.chernia...@t-systems.com wrote: Hi Duncan , Thank you for your answer, you mean R path? I have i

Re: [R] Error with devTools

2020-04-14 Thread Iurii.Cherniatin
Hi Duncan , Thank you for your answer, you mean R path? I have in PATH "C:\Program Files\R\R-3.6.2\bin\x64" Maybe you can provide me , how I can switch quiet = TRUE to False? -Original Message- From: Duncan Murdoch Sent: Monday, April 13, 2020 11:33 PM To: Cherniatin, Iuri