Re: [R] How to stratify data with multiple group simultaneously with R ggplot2?

2025-06-08 Thread Jeff Newmiller via R-help
aes(x=x, y=y, colour=w, group=w)) + > geom_line(linewidth=2) + > ggtitle("A+B") >ggplot(df[df$z=="A",], aes(x=x, y=y, colour=w, group=w)) + > geom_line(linewidth=2) + > ggtitle("A") >ggplot(df[df$z=="B",], aes(x=x, y=y, colour=w, group=w

[R] Repository of Examples and Problems from Lock5 textbook

2025-06-01 Thread Kevin Zembower via R-help
and formulas of basic statistics, but also know where the theory and numbers come from. One contribution to my knowledge of the material was the fact that I tried to work all the problems and homework in the course in R, even though the course itself never mentioned it or used it. It was still help

Re: [R] Simulating mid-points from a defined range

2025-05-31 Thread JRG via R-help
M Brian Smith briansmith199...@gmail.com >>> wrote: >>> >>> > Hi, >>> > >>> > Let say I have a range [0, 100] >>> > >>> > Now I need to simulate 1000 10 mid-points within the range with >>> > accuracy upto

Re: [R] Simulating mid-points from a defined range

2025-05-31 Thread JRG via R-help
ge with > > accuracy upto second decimal number. > > > > Let say, one simulated set is > > > > X1, X2, ..., X10 > > > > Ofcourrse > > > > X1 < X2 < ... > > > I have one more constraint that the differ

Re: [R] Simulating mid-points from a defined range

2025-05-31 Thread Jeff Newmiller via R-help
number. >> >> Let say, one simulated set is >> >> X1, X2, ..., X10 >> >> Ofcourrse >> >> X1 < X2 < ... > >> I have one more constraint that the difference between any 2 >> consecutive mid-points shall be at-least 5.00. >&g

Re: [R] Failed to convert text to date

2025-05-31 Thread Jeff Newmiller via R-help
Could you please help why I am getting NA value? > >______ >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see >https://stat.ethz.ch/mailman/listinfo/r-help >PLEASE do read the posting guide https://www.R-project.org/posting-guide.html >and provide

Re: [R] constructing a matrix for rgl plots

2025-05-31 Thread Jeff Newmiller via R-help
ould still have your x and y partition variables from when you created the data frame, and you should be able to construct the matrix using the matrix() constructor (not the as.matrix function) from your data frame z column. ?matrix On May 31, 2025 4:04:20 AM PDT, ravi via R-help wrote: >H

[R] constructing a matrix for rgl plots

2025-05-31 Thread ravi via R-help
phi = 20) :   At least one coordinate must be a matrix  How do I get z in the form of a matrix? Thanks. ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] Need r help asap

2025-05-30 Thread Jeff Newmiller via R-help
I am sorry to hear that you are having difficulty with your computer. However, this mailing list is about the R programming language.. not about text editors or about file recovery. I suggest you hire a local computer consultant familiar with file recovery on your operating system. There may

Re: [R] Looking for a function or a set of steps

2025-05-29 Thread Mike Day via R-help
gt; Paul Zachos, PhD >> Director, Research and Evaluation >> Association for the Cooperative Advancement of Science and Education >> (ACASE) >> 110 Spring Street Saratoga Springs, NY 12866 | >> p...@acase.org | www.acase.org >> >> >> >&g

[R] Only one label from axis() is shown

2025-05-28 Thread Marc Girondot via R-help
quot;, "", "", "", "Jul-2023", "", "", "", "", "",       "Jan-2024", "", "", "", "", "",

Re: [R] how to read a PSB file in R?

2025-05-27 Thread Ranjan Maitra via R-help
On Tue May20'25 12:15:41AM, Ranjan Maitra via R-help wrote: > From: Ranjan Maitra via R-help > Date: Tue, 20 May 2025 00:15:41 -0500 > To: r-help@r-project.org > Reply-To: Ranjan Maitra > Subject: Re: [R] how to read a PSB file in R? > > On Tue May20'25 05:56:59A

Re: [R] how to read a PSB file in R?

2025-05-26 Thread Ranjan Maitra via R-help
On Tue May20'25 12:15:41AM, Ranjan Maitra via R-help wrote: > From: Ranjan Maitra via R-help > Date: Tue, 20 May 2025 00:15:41 -0500 > To: r-help@r-project.org > Reply-To: Ranjan Maitra > Subject: Re: [R] how to read a PSB file in R? > > On Tue May20'25 05:56:59A

Re: [R] Looking for a function or a set of steps

2025-05-26 Thread paul zachos via R-help
t; 1-x > >> On 18.05.2025, at 19:40, paul zachos via R-help wrote: >> >> Dear R Community >> >> I am an R beginner >> >> I have a vector of ‘1’s and ‘0’s >> >> x >> [1] 0 0 1 0 0 1 1 0 1 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 >> [28] 0

Re: [R] Formatting zeroes with prettyNum

2025-05-23 Thread Marttila Mikko via R-help
(In hindsight I should have used a `zero.print` value that looked less like a typo, e.g. `zero.print = "--"` in my example. Sorry about the potential confusion.) -Original Message----- From: R-help On Behalf Of Marttila Mikko via R-help Sent: Friday, 23 May 2025 13:21 To: How

Re: [R] Formatting zeroes with prettyNum

2025-05-23 Thread Marttila Mikko via R-help
Tim, The purpose of the `replace.zero` argument is to allow longer replacements. See for example the behaviour with a character vector input: > prettyNum("0", zero.print = "- ", replace.zero = TRUE) [1] "- " I'm pretty sure this is a bug, and have now p

Re: [R] Formatting zeroes with prettyNum

2025-05-23 Thread Howard, Tim G (DEC) via R-help
zero.print = " - ", replace = TRUE) [1] " " Warning message: In .format.zeros(x, zero.print, replace = replace.zero) : 'zero.print' is truncated to fit into formatted zeros; consider 'replace=TRUE' When zero.print is only one character, it doesn'

[R] Formatting zeroes with prettyNum

2025-05-23 Thread Marttila Mikko via R-help
ribution, or reliance upon the contents of this e-mail is strictly prohibited. If you have received this e-mail transmission in error, please reply to the sender, so that they can arrange for proper delivery, and then please delete the message from your computer systems. Thank you.

Re: [R] Why is there no macro facility for R?

2025-05-22 Thread Marc Schwartz via R-help
Hi, I suppose that I might be considered a grey-hair, both literally and figuratively, at least for what little hair I have left…. ;-) John might find this article by Thomas from R News in September of 2001 of interest. R News was the predecessor to the R Journal: https://journal.r

Re: [R] Looking for a function or a set of steps

2025-05-19 Thread Goodale, Tom via R-help
Surely doing y <- 1 - x would be the simplest way? Best, Tom > -Original Message- > From: R-help On Behalf Of Rui Barradas > Sent: 19 May 2025 08:08 > To: paul zachos ; r-help@r-project.org > Subject: Re: [R] Looking for a function or a set of steps > > Às 1

Re: [R] how to read a PSB file in R?

2025-05-19 Thread Ranjan Maitra via R-help
On Tue May20'25 05:56:59AM, Rui Barradas wrote: > From: Rui Barradas > Date: Tue, 20 May 2025 05:56:59 +0100 > To: Ranjan Maitra , r-help@r-project.org > Subject: Re: [R] how to read a PSB file in R? > > Às 03:17 de 20/05/2025, Ranjan Maitra via R-help escreveu: > >

[R] how to read a PSB file in R?

2025-05-19 Thread Ranjan Maitra via R-help
I have come across this file (warning, massive, 4.3 GB) https://esahubble.org/media/archives/images/original/heic1502a.psb and it appears to be a filetype I was not aware of previously. Is it possible to read the file in R using any tool? It is an image and I am looking for the RGB of the

[R] Very odd issue getting "Input/output error" running shiny app from index.html locally but same shiny on my server working fine

2025-05-19 Thread Chris Evans via R-help
I realise that shiny and Rstudio is often seen as OT here but I have a strong suspicion that the issue is R or R/OS related so I hope someone here will have some thoughts that might help me. The scenario is that as of yesterday running my shiny project locally from within Rtudio, i.e. by

Re: [R] Very odd issue getting "Input/output error" running shiny app from index.html locally but same shiny on my server working fine

2025-05-19 Thread Chris Evans via R-help
May 19 15:36 keyring    0 srwxrwxr-x  1 chris chris   0 May 19 15:36 kwallet5.socket    0 drwx--  2 chris chris  40 May 19 15:36 gvfsd    0 drwx--  2 chris chris  60 May 19 15:36 dconf    0 drwx------  2 chris chris  60 May 19 15:36 at-spi    4 -rw-rw-r--  1 chris chris  77 May 19 15:36 KSMse

[R] Looking for a function or a set of steps

2025-05-18 Thread paul zachos via R-help
Dear R Community I am an R beginner I have a vector of ‘1’s and ‘0’s x [1] 0 0 1 0 0 1 1 0 1 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 [28] 0 1 1 0 1 0 1 1 0 0 0 0 1 0 1 1 0 0 1 0 0 1 0 0 0 1 1 [55] 0 0 1 0 1 0 0 0 1 1 1 1 0 1 0 0 0 1 0 0 1 1 0 0 0 0 0 [82] 1 1 1 0 1 0 0 1 0 0 1 1 1 1 1 I would

Re: [R] customizing library locations for R in ubuntu

2025-05-15 Thread ravi via R-help
I have now followed your advice and switched to the R-sig-debian help list. Ravi On Thursday, 15 May 2025 at 12:59:05 CEST, ravi wrote: I did some googling and then ran: > bspm::shadowed_packages() Package LibPath Version   Shadow.LibPath Shadow.Version Shadow.Ne

Re: [R] customizing library locations for R in ubuntu

2025-05-15 Thread ravi via R-help
I did some googling and then ran: > bspm::shadowed_packages() Package LibPath Version   Shadow.LibPath Shadow.Version Shadow.Newer bspmbspm /usr/lib/R/site-library   0.5.7 /home/ravi/rvi/Rlib  0.5.7     FALSE I have a copy of bspm in the /usr/lib/R/s

[R] Different output type with as.Date

2025-05-15 Thread Barthelemy Tanguy via R-help
Hello, I'm encountering what seems to me to be an anomaly with the as.Date() function. If I fill in an origin or not, the function will not return the same type of object (integer or double). Here's a small example: ``` r as.Date(0L) |> typeof() #> [1] "integer" as.

Re: [R] customizing library locations for R in ubuntu

2025-05-14 Thread ravi via R-help
Thanks to Jeff and Ivan for your helpful comments. Ravi On Saturday, 10 May 2025 at 11:37:29 CEST, Ivan Krylov wrote: В Thu, 8 May 2025 19:39:40 + (UTC) ravi via R-help пишет: > In windows, I add the following line: > .libPaths(c(“C:/Rownlib”,”C:/R/R-4.5.0/library”)) >    

Re: [R] missing value where TRUE/FALSE needed with R ipolygrowth

2025-05-09 Thread Jeff Newmiller via R-help
ative numbers into powers or log or sqrt... kind of things. Read the documentation for your analysis packages carefully. On May 9, 2025 2:31:29 AM PDT, Luigi Marongiu wrote: >Dear R-Help, >I am trying to determine the growth rate of bacteria under specific >conditions using >ipo

Re: [R] customizing library locations for R in ubuntu

2025-05-09 Thread Ivan Krylov via R-help
В Thu, 8 May 2025 19:39:40 + (UTC) ravi via R-help пишет: > In windows, I add the following line: > .libPaths(c(“C:/Rownlib”,”C:/R/R-4.5.0/library”)) >   in the file C:/R/R-4.5.0/etc/Rprofile.site > > I have my own list of packages in the Rownlib folder and the packages &

Re: [R] empty `Rscript -e "Rcpp:::LdFlags()"` prevents installation

2025-05-09 Thread Ralf Goertz via R-help
gt; to the package author or is it a problem common enough so that > developer's guidelines should address this? Sorry for the noise. Backticks were not the problem. For those interested: I run R using the command konsole -e R to have it in its own terminal window. As I sometimes work on differ

[R] empty `Rscript -e "Rcpp:::LdFlags()"` prevents installation

2025-05-09 Thread Ralf Goertz via R-help
27;s guidelines should address this? ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, mi

Re: [R] customizing library locations for R in ubuntu

2025-05-08 Thread Jeff Newmiller via R-help
You might be better off just using the renv package. To your question, you should probably be reading the R Installation and Administration manual. Note that packages can be installed by the system administrator in *nix environments and the alternate libraries allow you to use some set of R

[R] customizing library locations for R in ubuntu

2025-05-08 Thread ravi via R-help
Hi, In Windows, I follow a method with customized library locations that has worked for me when upgrading to new R versions.  I have not been able to follow the same method in Ubuntu. I would like to have help. Let me explain. In windows, I add the following line: .libPaths(c(“C:/Rownlib”,”C:/R

Re: [R] Help merging large datasets in R

2025-05-08 Thread Jeff Newmiller via R-help
dput function is another big help in constructing this. The help list really works best when we share code snippets that don't work right in our R sessions and comment on them. Make an effort to learn how your email client can be configured to compose your email in plain text so the formattin

Re: [R] Help merging large datasets in R

2025-05-07 Thread Jeff Newmiller via R-help
ers. People also often have to work with column names provided by an external source. It can be harder to explain to people familiar with the original data that you renamed all the columns they see because it was inconvenient not to. If you have that luxury, fine... but R can absolutely avoid mung

[R] Help merging large datasets in R

2025-05-07 Thread Deelen, M. (Mirjam) via R-help
Hi guys, For my MSc. thesis i am using R studio. The goal is for me to merge a couple (6) of relatively large datasets (min of 200.000 and max of 2mil rows). I have now been able to do so, however I think something might be going wrong in my codes. For reference, i have a dataset 1 (200.000

[R] OT: A philosophical question about statistics

2025-05-06 Thread Gregg Powell via R-help
> > they’re more common in teaching. Meanwhile, classic Normal and t > > methods aren’t going away – they’re fundamental and still useful. > > Future students will continue to learn both, getting the best of both > > worlds. > > > > Good luck in your studies! >

Re: [R] OT: A philosophical question about statistics

2025-05-06 Thread Kevin Zembower via R-help
didn't write to complain. I promise to limit off-topic questions in the future. -Kevin On Mon, 2025-05-05 at 15:17 +, Kevin Zembower wrote: > I marked this posting as Off Topic because it doesn’t specifically > apply to R and Statistics, but is rather a general question about >

Re: [R] OT: A philosophical question about statistics

2025-05-06 Thread Kevin Zembower via R-help
what > assumption or which test is problematic and why? > > Tim __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] OT: A philosophical question about statistics

2025-05-06 Thread Kevin Zembower via R-help
till useful. > Future students will continue to learn both, getting the best of both > worlds. > > Good luck in your studies! > gregg ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] OT: A philosophical question about statistics

2025-05-06 Thread Kevin Zembower via R-help
the easiest and quickest part. Thank you again, Bert, for replying. I always enjoy your contributions to this group. -Kevin __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] non-reproducible eigen() output with MKL

2025-05-06 Thread smallepsilon via R-help
ago where this was discussed: > > https://www.stat.math.ethz.ch/pipermail/r-help/2023-August/477904.html > > I generally use: > > export OPENBLAS_NUM_THREADS=1 > export MKL_NUM_THREADS=1 > > since in my experience the biggest performance gains come from switching to

[R] OT: A philosophical question about statistics

2025-05-05 Thread Gregg Powell via R-help
going away – they’re fundamental and still useful. Future students will continue to learn both, getting the best of both worlds. Good luck in your studies! gregg On Monday, May 5th, 2025 at 8:17 AM, Kevin Zembower via R-help wrote: > > > I marked this posting as Off Topic because i

[R] OT: A philosophical question about statistics

2025-05-05 Thread Kevin Zembower via R-help
I marked this posting as Off Topic because it doesn’t specifically apply to R and Statistics, but is rather a general question about statistics and the teaching of statistics. If this is annoying to you, I apologize. As I wrap up my work in my beginning statistics course, I’d like to ask a

Re: [R] non-reproducible eigen() output with MKL

2025-05-04 Thread smallepsilon via R-help
Peter, The eigenvalues are not identical(), but are all.equal(). When n is 20, the crossproduct is (numerically) a diagonal matrix with +-1 on the diagonal. When n is 50, this is not the case, but that could be an issue of nearly identical eigenvalues. Is there no way within R to require that

[R] Estimating regression with constraints in model coefficients - Follow-up on Constrained Ordinal Model — Optimized via COBYLA

2025-05-04 Thread Gregg Powell via R-help
ma::augLag(), which allows both equality and bound constraints and uses augmented Lagrangian methods — possibly offering improved precision with gradient-based control. Happy to assist with any of those, as time permits - perhaps next week. r/ Gregg On Thursday, May 1st, 2025 at 1:01

[R] non-reproducible eigen() output with MKL

2025-05-04 Thread smallepsilon via R-help
I am using MKL with R 4.5.0 on Linux, and eigen() is producing different results with identical calls. Specifically, when I run the code below, I get "FALSE" from identical(). Just in case it had something to do with a random number generator, I put identical set.seed() calls immediat

Re: [R] Estimating regression with constraints in model coefficients

2025-05-01 Thread Gregg Powell via R-help
constraints: • ∑β(1)=1.60 \ sum β^{(1)} = 1.60∑β(1)=1.60 • ∑β(2)=1.60 \ sum β^{(2)} = 1.60∑β(2)=1.60 3. Element-wise bounds applied to each β set: • lower = c(1, -1, 0) • upper = c(2, 1, 1) Planning to wrap this into an updated nloptr optimization routine. I’ll work on a .R script as time

Re: [R] Overnight Cluster (Whitepaper)?

2025-04-30 Thread Jeff Newmiller via R-help
ut. (The sharing would only be on the local >network, not the entire internet, making them feel more comfortable with >it.) > >Ideally, we would then have a frontend R (controller) that could run >`mclapply` statements on this Franken-computer, and be smart enough about >how to distrib

Re: [R] Overnight Cluster (Whitepaper)?

2025-04-30 Thread Ivan Krylov via R-help
to the worker nodes or even rely on the nodes being able to accept incoming connections. It's possible to run a BOINC server yourself [1], although the server side will take some work to set up, and the jobs need to be specially packaged. In theory, one could package R as a BOINC app and arra

Re: [R] return inconsistency?

2025-04-30 Thread Jeff Newmiller via R-help
The R antibugging practice here is to not use the return function. The expression on the last line of the function is automatically the return value of the function. Some people use return within conditionals in the function, but when I have conditional execution flow I prefer to simply assign

Re: [R] return inconsistency?

2025-04-30 Thread Ivan Krylov via R-help
On Wed, 30 Apr 2025 11:15:02 +0200 Ralf Goertz via R-help wrote: > If this is not an error what is its purpose? >From the point of view of the R syntax, everything is an expression. One of the uses of return() being an expression is base::callCC(). The ability to use it inside an expr

[R] return inconsistency?

2025-04-30 Thread Ralf Goertz via R-help
ariant (which returns the value of the numerator only) not a syntax error? I would have expected R to report something like > Error: unexpected '/' in "return(OR^2+6*OR+1)/" If this is not an error what is its purpose? ______ R-help@r-p

Re: [R] Estimating regression with constraints in model coefficients

2025-04-29 Thread Gregg Powell via R-help
want to apply separate lower/upper bounds to each of the six β coefficients (and if so, what are they for each)? Once I understand this last part better, I’ll see about working on a version that fits this updated structure and constraint logic. As always – no promises. r/ Gregg Powell Sierra Vist

Re: [R] Possible bug in gzcon() (6161:src/main/connections.c)

2025-04-26 Thread Ivan Krylov via R-help
ader=F)) > > # [1] 1798 > > > # local > > download.file(addr, destfile=basename(addr)) > > nrow(read.csv(gzcon(file(basename(addr), "r"), text=T), header=F)) > > # [1] 429498 I can reproduce the problem (with slightly different numbers): length(readLines(

Re: [R] 4.5.0: Do NOT just copy library folder and update.packages()

2025-04-25 Thread Jeff Newmiller via R-help
Don't copy installed packages. There are also periodically changes in the compiler toolchain, and many packages have compiled code in them that can misbehave if you mix old compiled code and new compiled code. The kinds of errors you get can range from minor random answers to crashing R.

[R] 4.5.0: Do NOT just copy library folder and update.packages()

2025-04-25 Thread Peter Dalgaard via R-help
.5.0. One of them has tools in the 4.4 library and the other does not. I have no clue what the difference might be -- Peter Dalgaard, Professor, Center for Statistics, Copenhagen Business School Solbjerg Plads 3, 2000 Frederiksberg, Denmark Phone: (+45)38153501 Office: A 4.23 Email: pd@c

Re: [R] How to find inverse of glm model?

2025-04-24 Thread Gregg Powell via R-help
nt"), lin)) : > > > NA/NaN/Inf in foreign function call (arg 5) > > > ``` > > > How can I properly set this regression model? > > > Thank you > > > > > On Wed, Apr 16, 2025 at 7:08 AM Luigi Marongiu marongiu.lu...@gmail.com > &g

Re: [R] Estimating regression with constraints in model coefficients

2025-04-24 Thread Gregg Powell via R-help
- Constraint functions: sum(β) = 1.60 and increasing cutpoints - Optimization via nloptr() Hopefully, you’ll be able to run it locally with only the VGAM, foreign, and nloptr packages. I’ll send the .R file along with the next email. A best attempt, anyway. r/ Gregg “Oh, what fun it is

Re: [R] How to find inverse of glm model?

2025-04-23 Thread Gregg Powell via R-help
& Statistics > > > University of Melbourne, VIC 3010 Australia > > > Tel: (+61) 0403 138 955 > > > Email: a...@unimelb.edu.au > > > Website: https://researchers.ms.unimelb.edu.au/~apro@unimelb/ > > > > > > I acknowledge the Traditional Ow

Re: [R] Estimating regression with constraints in model coefficients

2025-04-23 Thread Gregg Powell via R-help
lel with theory, if you'd like a working R example coded from scratch — with: • a custom likelihood for an ordinal (cumulative logit) model, • fixed thresholds / no intercept, • coefficient bounds, • and a sum constraint on β I’d be happy to attempt that using nloptr() or constrOptim(). You

Re: [R] Estimating regression with constraints in model coefficients

2025-04-21 Thread Jeff Newmiller via R-help
, Christofer Bogaso wrote: >Hi Gregg, > >I am sincerely thankful for this workout. > >Could you please suggest any text book on how to create log-likelihood >for an ordinal model like this? Most of my online search point me >directly to some R function etc, but a theoretical discus

Re: [R] Estimating regression with constraints in model coefficients

2025-04-21 Thread Gregg Powell via R-help
Christofer, Given the constraints you mentioned—bounded parameters, no intercept, and a sum constraint—you're outside the capabilities of most off-the-shelf ordinal logistic regression functions in R like vglm or polr. The most flexible recommendation at this point is to implement c

Re: [R] problem with my base_df function ?

2025-04-16 Thread varin sacha via R-help
the following error , at the following point in the code ..." ) On 2025-04-16 12:11 p.m., varin sacha via R-help wrote: > R-experts, > > The R script here below. > > How to solve my problem ? > > Best, > > > ## > # Load packa

[R] problem with my base_df function ?

2025-04-16 Thread varin sacha via R-help
R-experts, The R script here below. How to solve my problem ?  Best, ## # Load packages   install.packages("remotes") remotes::install_github("bd2kccd/r-causal")   # Install 'gssr' from 'ropensci' universe install.packag

Re: [R] How to find inverse of glm model?

2025-04-15 Thread Andrew Robinson via R-help
y of Melbourne, VIC 3010 Australia Tel: (+61) 0403 138 955 Email: a...@unimelb.edu.au Website: https://researchers.ms.unimelb.edu.au/~apro@unimelb/ I acknowledge the Traditional Owners of the land I inhabit, and pay my respects to their Elders. On 16 Apr 2025 at 1:01 AM +1000, Gregg Powell via R-

Re: [R] How to find inverse of glm model?

2025-04-15 Thread Gregg Powell via R-help
tted a glm model to some data; how can I find the inverse > function of this model? Since I don't know the y=f(x) implemented by > glm (this works under the hood), I can't define a f⁻¹(y). > Is there an R function that can find the inverse of a glm model? > Thank you. > > The

Re: [R] Drawing a sample based on certain condition

2025-04-15 Thread Jeff Newmiller via R-help
ng execution >time? Are you planning on looking at all t and T within a range? > >Tim > >-Original Message- >From: R-help On Behalf Of Bert Gunter >Sent: Monday, April 14, 2025 4:16 PM >To: Duncan Murdoch >Cc: r-help@r-project.org >Subject: Re: [R] Drawing a sa

Re: [R] An opinion question, please

2025-04-10 Thread Jeff Newmiller via R-help
remains handled as arguments and return values rather than as data in the object itself. The lm class in base R uses a "constructor computes and methods retrieve results" approach... which isn't quite as flexible as a transformer approach but still hides the gory details. My re

[R] Error in running get_acs()

2025-04-09 Thread Deana Kittaneh via R-help
Hi R team!     Since last Friday 04/04, my team and I have faced an error with running  the 'get_acs()' command from the tidycensus package. The code we ran and the error message we received are shown below. Our troubleshooting efforts showed that: 1. When we run the code with

Re: [R] Estimating regression with constraints in model coefficients

2025-04-08 Thread Gregg Powell via R-help
there are ways to implement constraints on parameter estimates in ordinal logistic regression in R. Here are a few approaches: The rms package (Regression Modeling Strategies) by Frank Harrell offers the lrm function which can handle constraints through its penalty parameter, though it&#

Re: [R] Request to Unsubscribe from R Forum Replies

2025-04-07 Thread David Winsemius via R-help
ote: > > Hello, > > I would like to request the removal of my email address from the R forum > reply/update list. I no longer wish to receive notifications or messages > related to forum discussions. > > Thank you for your attention and understanding. > > Best re

Re: [R] Setting up hypothesis tests with the infer library?

2025-04-05 Thread Kevin Zembower via R-help
all been simulations, bootstraps, randomized distributions, etc. Thank you, again, Rui and Michael, for your help for me. -Kevin On Sat, 2025-03-29 at 16:42 +, Rui Barradas wrote: > Às 16:09 de 29/03/2025, Kevin Zembower via R-help escreveu: > > Hello, all, > > > > We'r

Re: [R] Setting up hypothesis tests with the infer library?

2025-03-31 Thread Kevin Zembower via R-help
in my statistics class and how I was doing it in R. Thanks, all who contributed to this thread. Thanks, again, Neal, for your help. -Kevin On Sat, 2025-03-29 at 13:46 -0700, Neal Fultz wrote: > > > > I've been setting up problems like this with code similar to: > > ==

Re: [R] Setting up hypothesis tests with the infer library?

2025-03-29 Thread David Winsemius via R-help
> On Mar 29, 2025, at 9:59 AM, Kevin Zembower via R-help > wrote: > > Hi, Rui and Michael, thank you both for replying. > > Yeah, I'm not supposed to know about Chi-squared yet. So far, all of > our work with hypothesis tests has involved creating the sample dat

[R] Setting up hypothesis tests with the infer library?

2025-03-29 Thread Kevin Zembower via R-help
Hello, all, We're now starting to cover hypothesis tests in my Stats 101 course. As usual in courses using the Lock5 textbook, 3rd ed., the homework answers are calculated using their StatKey application. In addition (and for no extra credit), I'm trying to solve the problems using R. I

[R] 3 way crosstable not working

2025-03-25 Thread varin sacha via R-help
Dear R-experts, Here below a toy example not working. After some researches on the Net, still don't get it ! Many thanks for your precious help. # library(knitr) library(ggplot2) library(pollster) library(dplyr)   statut=c("married","not ma

Re: [R] PLOTTING ODE MODEL RESULTS USING PLOT.DESOLVE FROM THE DESOLVE PACKAGE

2025-03-25 Thread Jeff Newmiller via R-help
rvations. I checked the >vignettes but did not see this incorporated. > >Mariam. > > [[alternative HTML version deleted]] > >__ >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see >https://stat.ethz.ch/ma

Re: [R] how to create model matrix of second order terms

2025-03-25 Thread Stephen Bond via R-help
025, Stephen Bond via R-help escreveu: > > Folks, > > > > I appreciate your effort, but maybe I was not explicit enough, so > > let > > me try again. > > > > The current setup for formulas does not allow for I(x^2) terms as > > explained

Re: [R] how to create model matrix of second order terms

2025-03-24 Thread Stephen Bond via R-help
entertain > others, and entertain herself." > > > > On Mon, Mar 24, 2025 at 12:22 AM Stephen Bond via R-help > wrote: > > I am sending to this forum as stackoverflow has devolved into sth > > pretty bad. > > Below code shows how to get what I want in a clu

[R] how to create model matrix of second order terms

2025-03-24 Thread Stephen Bond via R-help
tor crossings using formula a*b*c and then cross with the numerics, which is even more clumsy. Thanks everybody ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

Re: [R] Failure to install any packages: "malformed"

2025-03-20 Thread Ivan Krylov via R-help
re") to see if anything is different, but it probably won't be. -- Best regards, Ivan __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.

[R] Why I wrote my MWE the way I did. [WAS:] Re: What don't I understand about sample()?

2025-03-17 Thread Kevin Zembower via R-help
ure that at some point in the 15 years that I've been aware of and using R, read.csv() would not do that. I didn't do a lot with R during the time that the tidyverse was developed and became popular; I had to learn it fresh just a few years ago, when I kind of came back to R. I

Re: [R] MacPorts install of data.table lacks openmp support

2025-03-17 Thread Ivan Krylov via R-help
Hello Naresh, If you don't get a good answer here, consider asking later at r-sig-...@r-project.org. В Sun, 16 Mar 2025 20:28:49 + Naresh Gurbuxani пишет: > I installed gfortran 14.2 using package available at > https://mac.r-project.org. Then I installed openmp support (17.0

Re: [R] What don't I understand about sample()?

2025-03-17 Thread Jeff Newmiller via R-help
The original question was about sample, a base R function. Dragging in tidyverse along the way could be regarded as complicating the question unnecessarily, but in some cases there can be undesirable or simply unexpected interactions between functions drawn from different packages. Such

Re: [R] What don't I understand about sample()?

2025-03-15 Thread Kevin Zembower via R-help
bly lazy in not determining which of the multiple functions in the tidyverse library loads read_csv(), and just using that one. Thanks, again, for helping me to further understand R and this problem. -Kevin On Sat, 2025-03-15 at 12:00 +0100, r-help-requ...@r-project.org wrote: > Not having t

[R] [SPAM | WERBUNG] Re: What don't I understand about sample()?

2025-03-15 Thread Kevin Zembower via R-help
oid the trouble of typing the variable into R to verify the contents. My work is all contained in a Rmarkdown file, that I finally export and file with my notes from class to help me study for exams. Thank you, again, for your generous help for me. -Kevin On Sat, 2025-03-15 at 12:00 +0100, r

Re: [R] What don't I understand about sample()?

2025-03-14 Thread Kevin Zembower via R-help
t;- apply(random.samples, 1, compute.diff.means)) === I think both of these methods give me the data I'm trying for. Any suggestions on my R coding techniques are welcome. Thank you all, again, for taking the time and effort to help me. Your help is greatly appreciated.

Re: [R] What don't I understand about sample()?

2025-03-14 Thread Jorgen Harmse via R-help
Date: Thu, 13 Mar 2025 21:00:26 + From: Kevin Zembower To: r-help@r-project.org Subject: [R] What don't I understand about sample()? Message-ID: <01000195914ef9c4-7adadf5d-0069-4794-af09-454452b71c3d-000...@email.amazonses.com> Content-Type: text/plain; charset="ut

Re: [R] R GUI randomly resizes. Is this a known bug?

2025-03-13 Thread Ivan Krylov via R-help
Best regards, Ivan ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

[R] What don't I understand about sample()?

2025-03-13 Thread Kevin Zembower via R-help
t in class, along with its StatKey web application. I'm just trying to get more out of the class by also solving our problems using R, for which I'm not receiving any class credit. __________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and mo

Re: [R] Number changed weirdly when converting to numeric

2025-03-09 Thread Jeff Newmiller via R-help
4-converter/). > >Seems that decimal-to-float conversion has a bug on arm64. Note that I get the >same result with > >> x <- -177253333.33343267441 > >so it's not specific to as.numeric(). > >Best, >Stephanie > > > > >> On 9 Ma

Re: [R] Number changed weirdly when converting to numeric

2025-03-09 Thread Jeff Newmiller via R-help
https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-doesn_0027t-R-think-these-numbers-are-equal_003f https://0.30004.com/ On March 9, 2025 10:12:47 AM PDT, Christofer Bogaso wrote: >Hi, > >I have below simple conversion > >> sprintf("%0.15f", as.numeric

Re: [R] Issue with littler vs. R and source()

2025-03-08 Thread Steve Martin via R-help
Hi John, Does it work if you run R CMD r -i FailBill.R? Steve Original Message On 3/7/25 10:45, J C Nash wrote: > I want to use littler (i.e. "r -i ") to run an R script so I can > set up a clickable icon for a program which uses package staplr. > Act

Re: [R] Failed to convert data to numeric

2025-03-03 Thread Ivan Krylov via R-help
418180 6.7775277 > 3.2080840 > > [7] 4.1932877 0.3782577 4.6589550 NA There's an invisible Unicode character in there, U+FEFF ZERO WIDTH NO-BREAK SPACE: > dat2 |> tail(1) |> tools::showNonASCII() 1: -9.8814740 Try as.numeric(gsub('\ufeff

Re: [R] [Tagged] Re: Failed to convert data to numeric

2025-03-03 Thread Jeff Newmiller via R-help
?tools::showNonASCII On March 3, 2025 12:09:22 AM PST, Ivan Krylov via R-help wrote: >В Mon, 3 Mar 2025 13:21:31 +0530 >Christofer Bogaso пишет: > >> Is there any way to remove all possible "Unicode character" that may >> be present in the array at once? >

Re: [R] Failed to convert data to numeric

2025-03-03 Thread Ivan Krylov via R-help
ps://regex101.com/>. -- Best regards, Ivan ______ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] Code \255 no longer working to produce a short dash in base R PDF graphs

2025-02-21 Thread Paul Sherliker via R-help
Ivan Krylov wrote: >> text(1, 11, "baseline\255defined") >> text(1, 9, "done") >> graphics.off() >> >> They like that dash - but I never knew what it was called. >> >> Recently work updated my PC to the latest version of Wi

  1   2   3   4   5   6   7   8   9   10   >