[R] ] Applying a certain formula to a repeated sample data: RESOLVED

2018-11-28 Thread Ogbos Okike
Dear Jeff, This is great to me!!! Many, many thanks. I have also clicked the send plain text mode button and I hope this message will appear in plain text mode. Thanks again. Warmest regards. Ogbos On Wed, Nov 28, 2018 at 7:06 AM Jeff Newmiller wrote: > > Thank you for providing a clarifying

Re: [R] why the base::round(0.015, 2) returns 0.02?

2018-11-28 Thread Richard M. Heiberger
interesting. this looks like an OS problem, since ?round says ‘round’ rounds the values in its first argument to the specified number of decimal places (default 0). See ‘Details’ about “round to even” when rounding off a 5. Details Note that for rounding off a 5, the IEC 60559

Re: [R] why the base::round(0.015, 2) returns 0.02?

2018-11-28 Thread Duncan Murdoch
On 28/11/2018 8:49 AM, Philipp Upravitelev wrote: Dear colleagues, could you help me with the function base::round()? I can't understand how it works. For example, when I want to round 0.015 to the second digit, base::round() returns 0.02. But the real representation of the 0.015 is different:

Re: [R] why the base::round(0.015, 2) returns 0.02?

2018-11-28 Thread Rui Barradas
Hello, Your assumption that you can sprintf with 20 digits of precision is wrong, you only have 16 decimal digits. And sprintf('%.16f', 0.015) #[1] "0.0150" 0.015 == 0.0150 #[1] TRUE This rounds to the nearest even number, 0.02 (IEEE-754). Hope this helps, Rui Barra

Re: [R] gemo_text issue

2018-11-28 Thread Rui Barradas
Hello, Your code works but I suggest the following: 1) Instead of loading reshape2 to be used just once longData <- reshape2::melt(myData) 2) In the call to geom_text, aes() will find the x, y, etc values: zp1 + geom_text(data=test2, aes(x = con, y = Prob, label = Project, size = 6, color =

Re: [R] Bootstrapping One- and Two-Sample Hypothesis Tests of Proportion

2018-11-28 Thread Rui Barradas
Hello, What have you tried? Reproducible example please. http://adv-r.had.co.nz/Reproducibility.html https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example https://www.r-bloggers.com/minimal-reproducible-examples/ Rui Barradas Às 22:33 de 27/11/2018, Janh Anni

[R] why the base::round(0.015, 2) returns 0.02?

2018-11-28 Thread Philipp Upravitelev
Dear colleagues, could you help me with the function base::round()? I can't understand how it works. For example, when I want to round 0.015 to the second digit, base::round() returns 0.02. But the real representation of the 0.015 is different: > sprintf('%.20f', 0.015) [1] "0.0149994

Re: [R] R - Comparing BIC Results Between Expectation-Maximization (EM) and Linear Regression (LR) Algorithm

2018-11-28 Thread Sarah Goslee
Hi Andika, We don't do homework on this list, and your question is a statistics question rather than an R question anyway. That said, googling "interpreting BIC" should get you going, if talking to your professor and reading your textbook haven't helped. Sarah On Wed, Nov 28, 2018 at 11:30 AM A

[R] R - Comparing BIC Results Between Expectation-Maximization (EM) and Linear Regression (LR) Algorithm

2018-11-28 Thread Andika Putra Agustian
Hi there, I am trying to compare result of BIC (Bayesian Information Criterion) between Expectation-Maximization (EM) and Linear Regression (LR) Algorithm on "Hotel Occupancy" data using R, for my college task. The data contains data occupancy percentage from January to December 2017, based on is

Re: [R] detecting measurement of specific id in column in R

2018-11-28 Thread John Kane via R-help
No attached file. R-help is very fussy about what kind of file it will accept, A txt or pdf is the best bet. On the other hand it usually is best to include any code and sample data in the actual e-mail.  Use the function dput() as the best way to supply data. On Thursday, November 22, 2018

[R] High dimensional optimization in R

2018-11-28 Thread Ruben
Hi, Sarah Goslee (jn reply to  Basic optimization question (I'm a rookie)):  "R is quite good at optimization." I wonder what is the experience of the R user community with high dimensional problems, various objective functions and various numerical methods in R. In my experience with my p