Re: [R] Problem with creating a PCA graph in a loop

2024-05-08 Thread Gavin Duley
> On 8 May 2024, at 09:16, Ivan Krylov wrote: > > В Tue, 7 May 2024 16:57:14 +0200 > gavin duley пишет: > >> aes(label=current_rownames, >>colour=wine.data.filt$Treatment >> ) > > As you've noticed, aes() remembers variables by their name and > environment, not by value: Yes, it was

Re: [R] Problem with creating a PCA graph in a loop

2024-05-08 Thread Ivan Krylov via R-help
В Tue, 7 May 2024 16:57:14 +0200 gavin duley пишет: > aes(label=current_rownames, > colour=wine.data.filt$Treatment > ) As you've noticed, aes() remembers variables by their name and environment, not by value: str(ggplot2::aes(label = foo)) # List of 1 # $ label: language ~foo # <--

[R] Problem with creating a PCA graph in a loop

2024-05-07 Thread gavin duley
Hi all, I am having enormous problems with a loop that iterates over different levels in the factor wine.data$Time (levels T06, T09, and T12) and creates a PCA and graph for individuals at that time only. These graphs need to be accessible outside the loop, so I can combine them using

Re: [R] Problem with base::order

2024-04-10 Thread Sigbert Klinke
Hi, you are unfortunately right. Executing x <- sample(c(1,2,NA), 26, replace=TRUE) y <- sample(c(1,2,NA), 26, replace=TRUE) o <- order(x, y, decreasing = c(T,F), na.last=c(F,T)) cbind(x[o], y[o]) shows that the second entry of na.last is ignored without warning. Thanks Sigbert Am 10.04.24

Re: [R] Problem with base::order

2024-04-10 Thread Ivan Krylov via R-help
В Wed, 10 Apr 2024 09:33:19 +0200 Sigbert Klinke пишет: > decreasing=c(F,F,F) This is only documented to work with method = 'radix': >> For the ‘"radix"’ method, this can be a vector of length equal to >> the number of arguments in ‘...’ and the elements are recycled as >> necessary. For the

[R] Problem with base::order

2024-04-10 Thread Sigbert Klinke
Hi, when I execute order(letters, LETTERS, 1:26) then everything is fine. But if I execute order(letters, LETTERS, 1:26, na.last=c(T,T,T), decreasing=c(F,F,F)) I get the error message Error in method != "radix" && !is.na(na.last) : 'length = 3' in constraint to 'logical(1)' Shouldn't both

Re: [R] Problem with new version of R: Mutated vocals

2024-03-22 Thread Ivan Krylov via R-help
В Fri, 22 Mar 2024 16:11:14 + MACHO Siegfried via R-help пишет: > If I type the command: > Dir <- "C/Users/macho/Documents/_LVn/Experimentelle _bungen" > in the R console there is no problem. However, if I put the same > command into a source file (e.g. Test.r) and call this file from R >

[R] Problem with new version of R: Mutated vocals

2024-03-22 Thread MACHO Siegfried via R-help
Dear ladies and gentlemen, I have recently installed the latest version of R (4.3.3) for windows. Now I have the following problems with mutated vowels like �, �, etc. Here is an example: If I type the command: Dir <- "C/Users/macho/Documents/_LVn/Experimentelle �bungen" in the R console there

Re: [R] Problem when trying to install packages

2024-03-18 Thread peter dalgaard
2 things: 1) utils::install.packages() sometimes helps if the Rstudio version got wedged somehow. 2) You seem to be missing several Recommended packages (lattice, MASS, Matrix, nlme, cluster,). Did you install R without those? -pd > On 16 Mar 2024, at 05:09 , javad bayat wrote: >

Re: [R] Problem when trying to install packages

2024-03-16 Thread Uwe Ligges
On 16.03.2024 10:48, javad bayat wrote: Dear all; I found a useful video on youtube that has explained how to install Rtools. I followed the instructions and the problem was solved. " Installing R version 4.0 + RTools 4.0 + RStudio For Data Science (#R ?? A recent set of released software

Re: [R] Problem when trying to install packages

2024-03-16 Thread javad bayat
Dear all; I found a useful video on youtube that has explained how to install Rtools. I followed the instructions and the problem was solved. " Installing R version 4.0 + RTools 4.0 + RStudio For Data Science (#R #RTools #RStudio #DataScience) - YouTube

Re: [R] Problem when trying to install packages

2024-03-16 Thread Bert Gunter
Though Navigator may mess up any Rtools stuff because it handles the directory trees where packages and dependencies are located, does it not? If so, maybe just reinstall RStudio directly from its website to proceed. Just a guess obviously. Bert On Sat, Mar 16, 2024, 05:09 javad bayat wrote: >

Re: [R] Problem when trying to install packages

2024-03-16 Thread Bert Gunter
? Google it! "How to install packages using Rtools" Bert On Sat, Mar 16, 2024, 05:09 javad bayat wrote: > Dear Rui; > Many thanks for your reply. I have installed Rtools (rtools43-5958-5975) on > my PC and I have R version 4.3.3 and 4.3.2 to install. Also I have > installed Rstudio through

Re: [R] Problem when trying to install packages

2024-03-15 Thread javad bayat
Dear Rui; Many thanks for your reply. I have installed Rtools (rtools43-5958-5975) on my PC and I have R version 4.3.3 and 4.3.2 to install. Also I have installed Rstudio through Anaconda Navigator. But I do not know how to use Rtools for installing the R packages. I would be more than happy if

Re: [R] Problem with R coding

2024-03-12 Thread Ivan Krylov via R-help
В Tue, 12 Mar 2024 14:57:28 + CALUM POLWART пишет: > That's almost certainly going to be either the utf-8 character in the > path The problem, as diagnosed by Maria in the first post of the thread, is that the user home directory as known to R is stored in the ANSI encoding instead of

Re: [R] Problem with R coding

2024-03-12 Thread Iris Simmons
Hi Maria, I had something similar on my Windows work laptop at some point where the home directory was something containing non ASCII characters. The easy solution is to copy said directly from the file explorer into utils::shortPathName, and then set that as the home directory. In my case, >

Re: [R] Problem with R coding

2024-03-12 Thread CALUM POLWART
That's almost certainly going to be either the utf-8 character in the path OR the use of one drive which isn't really a subfolder as I understand it. When I've had these issues in the past, I've been able to mount a drive (say U:/ ) which sites further down /up the folder tree so that R just

Re: [R] Problem with R coding

2024-03-12 Thread Ivan Krylov via R-help
Dear Maria, I'm sorry for somehow completely missing the second half of your message where you say that you've already tried the workaround. В Tue, 12 Mar 2024 07:43:08 + Maria Del Mar García Zamora пишет: > I have tried to start R from CDM using: C:\Users\marga>set >

Re: [R] Problem with R coding

2024-03-12 Thread Ivan Krylov via R-help
В Tue, 12 Mar 2024 07:43:08 + Maria Del Mar García Zamora пишет: > Error: package or namespace load failed for ‘Rcmdr’: > .onLoad failed in loadNamespace() for 'tcltk2', details: > call: file.exists("~/.Rtk2theme") > error: file name conversion problem -- name too long? > > Once this

Re: [R] Problem with R coding

2024-03-12 Thread Rui Barradas
Às 07:43 de 12/03/2024, Maria Del Mar García Zamora escreveu: Hello, This is the error that appears when I try to load library(Rcmdr). I am using R version 4.3.3. I have tried to upload the packages, uninstall them and intalling them again and nothing. Loading required package: splines

Re: [R] Problem in R code

2023-11-09 Thread Ivan Krylov
В Wed, 8 Nov 2023 16:03:15 +0530 Crown Flame пишет: > for(i in 1:8) > { > LST_city <- extract(LST, c(lon[i],lat[i]), fun = mean, buffer = > 1, na.rm = TRUE) #error > } Three things you might need to change: 1. You are trying to assign the output of extract() to the same variable

[R] Problem in R code

2023-11-09 Thread Crown Flame
Good afternoon, I have been working on my thesis project on the topic "Urban Heat Island Pattern in India". To achieve the results I am applying a* two-dimensional Gaussian fit* on an LST raster of 1 km spatial resolution but I am facing two errors in the following code. library(raster) LST <-

Re: [R] Problem with compatible library versions

2023-10-13 Thread Sabine Braun
Thank you very much :-)), this worked! Now the loaded libraries are compatible with each other. Best regards Sabine Braun Am 11.10.2023 um 14:08 schrieb Richard O'Keefe: > There is a fairly straightforward way to load older versions > of packages, and that is to use the 'groundhog' package. >

Re: [R] Problem with compatible library versions

2023-10-12 Thread Richard O'Keefe
uld still run > without changes in 10 years? > Tim > > -Original Message- > From: R-help On Behalf Of Richard O'Keefe > Sent: Wednesday, October 11, 2023 8:08 AM > To: Uwe Ligges > Cc: r-help@r-project.org > Subject: Re: [R] Problem with compatible librar

Re: [R] Problem with compatible library versions

2023-10-11 Thread Uwe Ligges
Sent: Wednesday, October 11, 2023 8:08 AM To: Uwe Ligges Cc: r-help@r-project.org Subject: Re: [R] Problem with compatible library versions [External Email] There is a fairly straightforward way to load older versions of packages, and that is to use the 'groundhog' package. As the first sentence

Re: [R] Problem with compatible library versions

2023-10-11 Thread Ebert,Timothy Aaron
Is that a method where a program that I write today would still run without changes in 10 years? Tim -Original Message- From: R-help On Behalf Of Richard O'Keefe Sent: Wednesday, October 11, 2023 8:08 AM To: Uwe Ligges Cc: r-help@r-project.org Subject: Re: [R] Problem with compatible

Re: [R] Problem with compatible library versions

2023-10-11 Thread Richard O'Keefe
There is a fairly straightforward way to load older versions of packages, and that is to use the 'groundhog' package. As the first sentence of https://groundhogr.com/ puts it: Make your R scripts reproducible by replacing library(pkg) with groundhog.library(pkg, date). pkg can be a vector

Re: [R] Problem with compatible library versions

2023-10-11 Thread Uwe Ligges
On 10.10.2023 17:34, Sabine Braun wrote: On the github website I have reported several bugs with new versions of the tidyverse group (probably dplyr) which prevent me from using R normally. I wanted to go back to older versions but this seems not bo be easy. I downloaded R 4.1.2. and Rtools 40

[R] Problem with compatible library versions

2023-10-10 Thread Sabine Braun
On the github website I have reported several bugs with new versions of the tidyverse group (probably dplyr) which prevent me from using R normally. I wanted to go back to older versions but this seems not bo be easy. I downloaded R 4.1.2. and Rtools 40 but the library versions installed are

Re: [R] R - Problem retrieving memory used after gc() using arrow library

2023-08-16 Thread Ivan Krylov
On Wed, 16 Aug 2023 11:22:00 +0200 Kévin Pemonon wrote: > I'd like to understand why there's a difference in memory used > between the Windows task manager and R's memory.size(max=F) function. When R was initially ported to Windows, then-popular version of the system memory allocator was not a

[R] R - Problem retrieving memory used after gc() using arrow library

2023-08-16 Thread Kévin Pemonon
Hello, I'm using R versions 4.1.3 on Windows 10 and I'm having a problem with memory usage. Currently, I need to use the arrow and dplyr libraries in a program and when I compare the memory used between the windows task manager and the memory.size(max=F) function, the one given by the windows

Re: [R] Problem with filling dataframe's column

2023-06-14 Thread avi.e.gross
10:34 PM To: avi.e.gr...@gmail.com Cc: Bert Gunter ; R-help@r-project.org Subject: Re: [R] Problem with filling dataframe's column Consider m <- list(foo=c(1,2),"B'ar"=as.matrix(1:4,2,2),"!*#"=c(FALSE,TRUE)) It is a collection of elements of different types/structures

Re: [R] Problem with filling dataframe's column

2023-06-14 Thread Richard O'Keefe
be a good think. As far as I can tell, external > interface seem the same for now. > > One issue with R for a long time was how they did not do something more > like a Python dictionary and it looks like … > > ABOVE > > From: Bert Gunter > Sent: Tuesday, June 13,

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread avi.e.gross
and it looks like … ABOVE From: Bert Gunter Sent: Tuesday, June 13, 2023 6:15 PM To: avi.e.gr...@gmail.com Cc: javad bayat ; R-help@r-project.org Subject: Re: [R] Problem with filling dataframe's column Below. On Tue, Jun 13, 2023 at 2:18 PM mailto:avi.e.gr...@gmail.com> >

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread Bert Gunter
ot; and others like me call programming and that don't necessarily fit well together. > > > -Original Message- > From: R-help r-help-boun...@r-project.org On Behalf Of javad bayat > Sent: Tuesday, June 13, 2023 3:47 PM > To: Eric Berger ericjber...@gmail.com <mailto:er

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread avi.e.gross
June 13, 2023 3:47 PM To: Eric Berger ericjber...@gmail.com <mailto:ericjber...@gmail.com> Cc: R-help@r-project.org <mailto:R-help@r-project.org> Subject: Re: [R] Problem with filling dataframe's column Dear all; I used these codes and I get what I wanted. Sincerely pat = c("Level

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread Bill Dunlap
It is safer to use !grepl(...) instead of -grep(...) here. If there are no matches, the latter will give you a zero-row data.frame while the former gives you the entire data.frame. E.g., > d <- data.frame(a=c("one","two","three"), b=c(10,20,30)) > d[-grep("Q", d$a),] [1] a b <0 rows> (or

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread Rui Barradas
Às 17:18 de 13/06/2023, javad bayat escreveu: Dear Rui; Hi. I used your codes, but it seems it didn't work for me. pat <- c("_esmdes|_Des Section|0") dim(data2) [1] 281549 9 grep(pat, data2$Layer) dim(data2) [1] 281549 9 What does grep function do? I expected the

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread javad bayat
Dear all; I used these codes and I get what I wanted. Sincerely pat = c("Level 12","Level 22","0") data3 = data2[-which(data2$Layer == pat),] dim(data2) [1] 281549 9 dim(data3) [1] 244075 9 On Tue, Jun 13, 2023 at 11:36 AM Eric Berger wrote: > Hi Javed, > grep returns the positions

Re: [R] Problem with filling dataframe's column

2023-06-13 Thread Eric Berger
Hi Javed, grep returns the positions of the matches. See an example below. > v <- c("abc", "bcd", "def") > v [1] "abc" "bcd" "def" > grep("cd",v) [1] 2 > w <- v[-grep("cd",v)] > w [1] "abc" "def" > On Tue, Jun 13, 2023 at 8:50 AM javad bayat wrote: > > Dear Rui; > Hi. I used your codes, but it

Re: [R] Problem with filling dataframe's column

2023-06-12 Thread javad bayat
Dear Rui; Hi. I used your codes, but it seems it didn't work for me. > pat <- c("_esmdes|_Des Section|0") > dim(data2) [1] 281549 9 > grep(pat, data2$Layer) > dim(data2) [1] 281549 9 What does grep function do? I expected the function to remove 3 rows of the dataframe. I do

Re: [R] Problem with filling dataframe's column

2023-06-12 Thread Rui Barradas
Às 23:13 de 12/06/2023, javad bayat escreveu: Dear Rui; Many thanks for the email. I tried your codes and found that the length of the "Values" and "Names" vectors must be equal, otherwise the results will not be useful. For some of the characters in the Layer column that I do not need to be

Re: [R] Problem with filling dataframe's column

2023-06-11 Thread avi.e.gross
mutate() or other methods. -Original Message- From: R-help On Behalf Of javad bayat Sent: Sunday, June 11, 2023 4:05 PM To: R-help@r-project.org Subject: [R] Problem with filling dataframe's column Dear R users; I am trying to fill a column based on a specific value in another column of

Re: [R] Problem with filling dataframe's column

2023-06-11 Thread Rui Barradas
Às 13:18 de 11/06/2023, Rui Barradas escreveu: Às 22:54 de 11/06/2023, javad bayat escreveu: Dear Rui; Many thanks for your email. I used one of your codes, "data2$LU[which(data2$Layer == "Level 12")] <- "Park"", and it works correctly for me. Actually I need to expand the codes so as to

Re: [R] Problem with filling dataframe's column

2023-06-11 Thread Rui Barradas
Às 22:54 de 11/06/2023, javad bayat escreveu: Dear Rui; Many thanks for your email. I used one of your codes, "data2$LU[which(data2$Layer == "Level 12")] <- "Park"", and it works correctly for me. Actually I need to expand the codes so as to consider all "Levels" in the "Layer" column. There are

Re: [R] Problem with filling dataframe's column

2023-06-11 Thread javad bayat
Dear Rui; Many thanks for your email. I used one of your codes, "data2$LU[which(data2$Layer == "Level 12")] <- "Park"", and it works correctly for me. Actually I need to expand the codes so as to consider all "Levels" in the "Layer" column. There are more than hundred levels in the Layer column.

Re: [R] Problem with filling dataframe's column

2023-06-11 Thread Rui Barradas
Às 21:05 de 11/06/2023, javad bayat escreveu: Dear R users; I am trying to fill a column based on a specific value in another column of a dataframe, but it seems there is a problem with the codes! The "Layer" and the "LU" are two different columns of the dataframe. How can I fix this? Sincerely

[R] Problem with filling dataframe's column

2023-06-11 Thread javad bayat
Dear R users; I am trying to fill a column based on a specific value in another column of a dataframe, but it seems there is a problem with the codes! The "Layer" and the "LU" are two different columns of the dataframe. How can I fix this? Sincerely for (i in 1:nrow(data2$Layer)){ if

[R] problem in arfima in forecast...

2023-04-25 Thread akshay kulkarni
Dear members, I am using the forecast package for arfima modelling. THe following is the code: > arfima(ygrpch(OHLCDataEP[[1]])) Call: arfima(y = ygrpch(OHLCDataEP[[1]])) *** Warning during (fdcov) fit: unable to compute correlation matrix; maybe change 'h'

Re: [R] problem installing RUcausal library

2023-04-23 Thread Jeff Newmiller
Perhaps read the Posting Guide, note that there is a special mailing list for MacOSX-specific questions, and post there instead? You don't appear to have installed gfortran. I am aware that there are specific instructions for getting that installed in MacOS that you need to find and follow

Re: [R] problem installing RUcausal library

2023-04-23 Thread Ivan Krylov
В Sat, 22 Apr 2023 19:41:59 + (UTC) varin sacha via R-help пишет: > Working with a MAC, I have tried to install the RUcausal library > (copy and paste the installation command). For Mac-related problems, try r-sig-...@r-project.org. > ld: warning: directory not found for option >

[R] problem installing RUcausal library

2023-04-22 Thread varin sacha via R-help
Me again ! How to solve this? At the end of this page there is the installation command : https://gitlab.science.ru.nl/gbucur/RUcausal/-/blob/master/README.Rmd Working with a MAC, I have tried to install the RUcausal library (copy and paste the installation command). It is written that the

Re: [R] problem installing RGBL library

2023-04-22 Thread varin sacha via R-help
Bert, Thanks ! It works ! Best, Le samedi 22 avril 2023 à 19:42:18 UTC+2, Bert Gunter a écrit : Is lvida.R in your working directory? Try using the full path name to the file instead in source() -- Bert On Sat, Apr 22, 2023 at 9:38 AM varin sacha via R-help wrote: > > The

Re: [R] problem installing RGBL library

2023-04-22 Thread Bert Gunter
Is lvida.R in your working directory? Try using the full path name to the file instead in source() -- Bert On Sat, Apr 22, 2023 at 9:38 AM varin sacha via R-help wrote: > > The problem is that I am trying to run this R code : > https://github.com/dmalinsk/lv-ida/blob/master/example.R > > > So I

Re: [R] problem installing RGBL library

2023-04-22 Thread varin sacha via R-help
The problem is that I am trying to run this R code : https://github.com/dmalinsk/lv-ida/blob/master/example.R   So I run : library(pcalg) library(igraph) library(RBGL) source("lvida.R") Here is what I get : source("lvida.R") Error in file(filename, "r", encoding = encoding) :   cannot open

Re: [R] problem installing RGBL library

2023-04-22 Thread Eric Berger
looks fine. what's the problem? On Sat, Apr 22, 2023 at 7:27 PM varin sacha wrote: > Eric, > > Here it is : > > > library(RBGL) > Loading required package: graph > Loading required package: BiocGenerics > > Attaching package: ‘BiocGenerics’ > > The following objects are masked from

Re: [R] problem installing RGBL library

2023-04-22 Thread varin sacha via R-help
Eric, Here it is : library(RBGL) Loading required package: graph Loading required package: BiocGenerics Attaching package: ‘BiocGenerics’ The following objects are masked from ‘package:igraph’:   normalize, path, union The following objects are masked from ‘package:stats’:   IQR, mad, sd,

Re: [R] problem installing RGBL library

2023-04-22 Thread Eric Berger
What happens with the command > library(RBGL) On Sat, Apr 22, 2023 at 7:08 PM varin sacha via R-help wrote: > Dear R-experts, > > How to solve that problem? > > My R version is 4.2.1 > > Here below trying to install RGBL library found here : >

[R] problem installing RGBL library

2023-04-22 Thread varin sacha via R-help
Dear R-experts, How to solve that problem? My R version is 4.2.1 Here below trying to install RGBL library found here :  https://bioconductor.org/packages/release/bioc/html/RBGL.html So, I run this R code : if (!require("BiocManager", quietly = TRUE)) install.packages("BiocManager")

Re: [R] Problem of intercept?

2023-02-22 Thread varin sacha via R-help
Dear Peter, Bert and Timothy, Really appreciated your help. I guess Peter's comments were the nearest of what I was trying to do. I have tried but it still does not work. I mean the graph is showing the coefficients I am not expecting ! I will try to explain.  Starting from the equation : Y =

Re: [R] Problem of intercept?

2023-02-22 Thread peter dalgaard
Not sure what you are trying to do here. The immediate issue is that you are getting 'y' on the RHS, because that is the 1st column in Dataset. So "for (i in 2:3)" might be closer to intention. However, a 0/1 regresson with no intercept implies that the mean for the "0" group is zero, and

Re: [R] Problem of intercept?

2023-02-21 Thread Bert Gunter
Sigh... In a linear model with qualitative predictor variables, models with and without intercepts are just different parameterizations of the *same* model. -- they produce exactly the same predicted responses. So what do you mean? Search on "contrasts in linear models R" and similar for an

[R] Problem of intercept?

2023-02-21 Thread varin sacha via R-help
Dear R-experts, Here below my R code working with quite a few warnings.  x11 and x12 are dichotomous variable (0=no and 1=yes). I substract 1 to ignore intercept. I would like not to ignore intercept. How to modify my R code because if I just remove -1 it does not work? y=

Re: [R] Problem to run python code in r markdown

2023-01-20 Thread avi.e.gross
lled somewhere on your machine. When you get things aligned, you will be fine. -Original Message- From: R-help On Behalf Of Kai Yang via R-help Sent: Friday, January 20, 2023 11:20 AM To: R-help Mailing List Subject: [R] Problem to run python code in r markdown Hi Team,I'm tryi

Re: [R] Problem to run python code in r markdown

2023-01-20 Thread Milan Glacier
Maybe it is the order. You called py_install() first and then called use_condaenv(). Perhaps you need to switch to your conda env first and then call py_install(). On 01/20/23 16:20, Kai Yang via R-help wrote: Hi Team,I'm trying to run python in R markdown (flexdashboard). The code is below:

Re: [R] Problem to run python code in r markdown

2023-01-20 Thread Eric Berger
You don't specify what platform you are on (linux / Windows / other), and what tools you are using. I am running a linux system and I have virtual environments set up. I set the environment variable RETICULATE_PYTHON to point to python (in my virtual environment). I am using RStudio, and I use the

[R] Problem to run python code in r markdown

2023-01-20 Thread Kai Yang via R-help
Hi Team,I'm trying to run python in R markdown (flexdashboard). The code is below: try Python= ```{r, include=FALSE, echo=TRUE}library(reticulate)py_install("numpy") use_condaenv("base") ``` ```{python}import numpy as np``` I got error message below: Error in py_call_impl(callable,

Re: [R] Problem with integrate(function(x) x^3 / sin(x), -pi/2, pi/2)

2023-01-07 Thread Ivan Krylov
On Sun, 8 Jan 2023 05:24:05 +0200 Leonard Mada via R-help wrote: > pracma::integral(function(x) x^3 / sin(x), -pi/2, pi/2 ) > # 3.385985 Note that at least one implementation used by pracma::integral has the same problem: pracma::integral(function(x) x^3/sin(x), -pi/2, pi/2, no_intervals=7) #

Re: [R] Problem with integrate(function(x) x^3 / sin(x), -pi/2, pi/2)

2023-01-07 Thread Andrew Simmons
`subdivisions` is the maximum number of subintervals. Looking here https://github.com/wch/r-source/blob/79298c499218846d14500255efd622b5021c10ec/src/appl/integrate.c#L1275 I'm not surprised that changing `subdivisions` has no effect on the outcome. The integration method from {pracma} might

Re: [R] Problem with integrate(function(x) x^3 / sin(x), -pi/2, pi/2)

2023-01-07 Thread Andrew Simmons
You're dividing 0 by 0, giving you NaN, perhaps you should try function(x) ifelse(x == 0, 0, x^3/sin(x)) On Sat, Jan 7, 2023, 22:24 Leonard Mada via R-help wrote: > Dear List-Members, > > I encounter a problem while trying to integrate the following function: > > integrate(function(x) x^3 /

[R] Problem with integrate(function(x) x^3 / sin(x), -pi/2, pi/2)

2023-01-07 Thread Leonard Mada via R-help
Dear List-Members, I encounter a problem while trying to integrate the following function: integrate(function(x) x^3 / sin(x), -pi/2, pi/2) # Error in integrate(function(x) x^3/sin(x), -pi/2, pi/2) : #  non-finite function value # the value should be finite: curve(x^3 / sin(x), -pi/2, pi/2)

Re: [R] Problem with Windows clipboard and UTF-8

2022-10-13 Thread Tomas Kalibera
Hi Andrew, On 9/30/22 15:05, Andrew Hart via R-help wrote: Hi everyone, Recently I upgraded to R 4.2.1 which now uses UTF-8 internally as its native encoding. Very nice. However, I've discovered that if I use writeClipboard to try and move a string containing accented characters to the

Re: [R] Problem with Windows clipboard and UTF-8

2022-09-30 Thread Rui Barradas
Hello, I can reproduce this. C:\Users\ruipb>R -q -e "writeClipboard('categoría'); sessionInfo()" > writeClipboard('categoría'); sessionInfo() R version 4.2.1 (2022-06-23 ucrt) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 22000) Matrix products: default

[R] Problem with Windows clipboard and UTF-8

2022-09-30 Thread Andrew Hart via R-help
Hi everyone, Recently I upgraded to R 4.2.1 which now uses UTF-8 internally as its native encoding. Very nice. However, I've discovered that if I use writeClipboard to try and move a string containing accented characters to the Windows clipboard and then try and paste that into another

Re: [R] Problem with installing packages in R

2022-09-15 Thread Eric Berger
Can you bring up R in a shell? Do you get the same message? (Also, set your email to send plain text. HTML versions are deleted.) On Thu, Sep 15, 2022 at 11:27 AM Farah Al Saifi wrote: > > Dear Sir/Madam > > After the update of the new version of R 4.2.1, an error message ( Error in >

[R] Problem with installing packages in R

2022-09-15 Thread Farah Al Saifi
Dear Sir/Madam After the update of the new version of R 4.2.1, an error message ( Error in nchar(homeDir): invalid multibyte string, element 1) appears every time i open RStudio. Also the following warning message appears in the console: In normalizePath (path.expand(path), winslash,

Re: [R] Problem installing R 4.2 on Ubuntu 20-04

2022-07-25 Thread Micha Silver
Just a guess: On 25/07/2022 17:43, Witold E Wolski wrote: I am failing to get R 4 installed on Ubuntu. I am following the instructions given here: https://cran.r-project.org/bin/linux/ubuntu/ These are the errors I am getting: parallels@ubuntu-linux-20-04-desktop:~/Downloads/fragpipe/bin$

Re: [R] Problem installing R 4.2 on Ubuntu 20-04

2022-07-25 Thread Bert Gunter
Better posted on R-sig-debian, I think. Cheers, Bert On Mon, Jul 25, 2022 at 7:44 AM Witold E Wolski wrote: > I am failing to get R 4 installed on Ubuntu. I am following the > instructions given here: > https://cran.r-project.org/bin/linux/ubuntu/ > > These are the errors I am getting: > >

Re: [R] Problem installing/updating nloptr...

2022-05-19 Thread Ivan Krylov
On Thu, 19 May 2022 19:50:56 -0400 Brian Lunergan wrote: > CMake Error: The source directory > "/tmp/RtmpCNCU3l/R.INSTALL21c510095118/nloptr/src/CMAKE_RANLIB=/usr/bin > /ranlib" does not exist. > Specify --help for usage, or press the help button on the CMake GUI. > Unknown argument -j > Unknown

[R] Problem installing/updating nloptr...

2022-05-19 Thread Brian Lunergan
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Evening folks: Running R 4.2.0 on Linux Mint 19.3. When I tried to update package nloptr the operation failed with this error text seeming to be key to the problem. CMake Error: The source directory

Re: [R] Problem downloading pcalg library/package

2022-03-24 Thread varin sacha via R-help
Ivan, Here is what I get : download.file('https://stat.ethz.ch/CRAN/src/contrib/PACKAGES','PACKAGES') essai de l'URL 'https://stat.ethz.ch/CRAN/src/contrib/PACKAGES' Erreur dans download.file("https://stat.ethz.ch/CRAN/src/contrib/PACKAGES",  :   impossible d'ouvrir l'URL

Re: [R] Problem downloading pcalg library/package

2022-03-24 Thread Ivan Krylov
On Thu, 24 Mar 2022 13:29:45 + (UTC) varin sacha wrote: > I have changed my CRANmirror to the Switzerland (ETHZ) one using the > function you sent to me chooseCRANmirror( ). It still does not work ! > I still cannot install the pcalg package ! That's odd. Do you see any error messages if

[R] Problem downloading pcalg library/package

2022-03-24 Thread varin sacha via R-help
Dear R-experts, Here below my sessionInfo( ). I cannot download the pcalg package/library. Is my R version too old ? sessionInfo() R version 4.1.2 (2021-11-01) Platform: x86_64-apple-darwin17.0 (64-bit) Running under: macOS High Sierra 10.13.6 Matrix products: default BLAS:  

Re: [R] Problem installing Rcmdr on version 4.1.2...

2022-03-04 Thread Ivan Krylov
On Fri, 4 Mar 2022 08:23:43 -0500 Brian Lunergan wrote: > Running R 4.1.2 on Linux Mint 19.3. > g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -I../inst/include > -I'/home/brian/R/x86_64-pc-linux-gnu-library/4.1/testthat/include' > -fpic -g -O2

Re: [R] Problem with data distribution

2022-02-17 Thread Ebert,Timothy Aaron
: Thursday, February 17, 2022 4:54 PM To: Bert Gunter Cc: r-help mailing list Subject: Re: [R] Problem with data distribution [External Email] :) :) On Thu, Feb 17, 2022 at 10:37 PM Bert Gunter wrote: > imo, with such simple data, a plot is mere chartjunk. A simple table(= > the distri

Re: [R] Problem with data distribution

2022-02-17 Thread Neha gupta
Why would you want to plot a vector of all zeros, btw?) > > > > > > > > > > > > library(dplyr) > > > > > > boxplot(filter(data, bug == 0))# nonsense > > > boxplot(filter(data, bug > 0), range = 0) > > > > > > # Anot

Re: [R] Problem with data distribution

2022-02-17 Thread Neha gupta
; > That is all the code I have. How can I provide a reproducible code ? > > > > How can I save this result? > > > > On Thu, Feb 17, 2022 at 8:00 PM Ebert,Timothy Aaron > wrote: > > > >> You pipe the filter but do not save the result. A reproducible example > &

Re: [R] Problem with data distribution

2022-02-17 Thread Neha gupta
Dear John, thanks a lot for the detailed answer. Yes, I am not an expert in R language and when a problem comes in, I google it or post it on these forums. (I have just a little bit experience of ML in R). On Thu, Feb 17, 2022 at 8:21 PM John Fox wrote: > Dear Nega gupta, > > On 2022-02-17

Re: [R] Problem with data distribution

2022-02-17 Thread John Fox
Dear Nega gupta, In the last point, I meant to say, "Finally, it's better to post to the list in plain-text email, rather than html (as the posting guide suggests)." (I accidentally inserted a "not" in this sentence.) Sorry, John On 2022-02-17 2:21 p.m., John Fox wrote: Dear Nega gupta,

Re: [R] Problem with data distribution

2022-02-17 Thread John Fox
Dear Neha gupta, I hope that I'm not overstepping my role when I say that googling solutions to specific problems isn't an inefficient way to learn a programming language, and will probably waste your time in the long run. There are many good introductions to R. Best, John On 2022-02-17

Re: [R] Problem with data distribution

2022-02-17 Thread Rui Barradas
- From: R-help On Behalf Of Neha gupta Sent: Thursday, February 17, 2022 1:55 PM To: r-help mailing list Subject: [R] Problem with data distribution [External Email] Hello everyone I have a dataset with output variable "bug" having the following values (at the bottom of this email). My adv

Re: [R] Problem with data distribution

2022-02-17 Thread Neha gupta
- > From: R-help On Behalf Of Neha gupta > Sent: Thursday, February 17, 2022 1:55 PM > To: r-help mailing list > Subject: [R] Problem with data distribution > > [External Email] > > Hello everyone > > I have a dataset with output variable "bug" having t

Re: [R] Problem with data distribution

2022-02-17 Thread Ebert,Timothy Aaron
You pipe the filter but do not save the result. A reproducible example might help. Tim -Original Message- From: R-help On Behalf Of Neha gupta Sent: Thursday, February 17, 2022 1:55 PM To: r-help mailing list Subject: [R] Problem with data distribution [External Email] Hello everyone

[R] problem with switching windows in RSelenium..

2021-12-22 Thread akshay kulkarni
dear Kim, Hope you are doing well. I am Akshay, from bengaluru, INDIA. I am stock trader and am using R for my research. More specifically, I am using RSelenium to scrape news articles. I am stuck in the problem related to RSelenium. I am not able to switch windows in Rselenium

Re: [R] problem: try to passing macro value into submit block

2021-12-21 Thread David Winsemius
On 12/21/21 6:00 PM, Kai Yang via R-help wrote: Hi team,I'm trying to pass macro variable into R script in Proc iml. I want to do change variable in color= and export the result with different file name.If I don't use macro, the code work well. But when I try to use macro below, I got error

[R] problem: try to passing macro value into submit block

2021-12-21 Thread Kai Yang via R-help
Hi team,I'm trying to pass macro variable into R script in Proc iml. I want to do change variable in color= and export the result with different file name.If I don't use macro, the code work well. But when I try to use macro below, I got error message: "Submit block cannot be directly placed in

[R] problem with RSelenium....

2021-12-18 Thread akshay kulkarni
dear members, I am using RSelenium. I have downloaded the java binary standalone server. I am running it in my windows powershell with the following command: java -jar selenium-server-standalone-4.0.0-alpha-2.jar (note that the command doesn't get finished in the

Re: [R] Problem with lm Giving Wrong Results

2021-12-03 Thread Labone, Thomas
Health University of South Carolina Columbia, South Carolina USA From: Sarah Goslee Sent: Friday, December 3, 2021 11:00 AM To: Labone, Thomas Cc: Bill Dunlap ; r-help@r-project.org Subject: Re: [R] Problem with lm Giving Wrong Results It might also be a BLAS

Re: [R] Problem with lm Giving Wrong Results

2021-12-03 Thread Sarah Goslee
t;Min. 1st Qu. MedianMean 3rd Qu.Max. > 0.3767 0.8204 0.9659 0.9947 1.1372 2.4772 > > > > > Thomas R. LaBone > PhD student > Department of Epidemiology and Biostatistics > Arnold School of Public Health > University of South Carolina > Columbia, South Carolina USA > > >

Re: [R] Problem with lm Giving Wrong Results

2021-12-03 Thread Labone, Thomas
h Carolina Columbia, South Carolina USA From: Labone, Thomas Sent: Thursday, December 2, 2021 11:53 AM To: Bill Dunlap Cc: r-help@r-project.org Subject: Re: [R] Problem with lm Giving Wrong Results > summary(fit) Call: lm(formula = log(k) ~ Z) Residuals:

  1   2   3   4   5   6   7   8   9   10   >