Re: [R] help with line graphs - rather lengthy to explain need

2018-11-29 Thread David L Carlson
I'm not sure we have enough details to answer your question, but you may need to think about organizing your spreadsheet differently. Perhaps one sheet that has just the data and a second sheet that has the sample number and the location. Import those separately into R. Your data are in wide fo

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

2018-11-29 Thread Janh Anni
Hi Marc, I see what you are saying. I will try re-running the* boot.two.per* function using 1's and 0's for the data and specifying mean as the parameter and see what happens. I will report back. Thanks so much for your kind assistance! Janh On Thu, Nov 29, 2018 at 7:07 PM Marc Schwartz wr

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

2018-11-29 Thread Marc Schwartz via R-help
Hi, I don't see Duncan's reply in the archive, but consider: > 1 / 4 [1] 0.25 > mean(c(1, 0, 0, 0)) [1] 0.25 > 3 / 9 [1] 0.333 > mean(c(1, 1, 1, 0, 0, 0, 0, 0, 0)) [1] 0.333 Regards, Marc Schwartz > On Nov 29, 2018, at 6:57 PM, Janh Anni wrote: > > Hi Bert, > > You mean, just c

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

2018-11-29 Thread Janh Anni
Hi Bert, You mean, just compute the test specifying the mean as the parameter but using 1's and 0's for the data? Also I don't get how a proportion is a mean of 0/1 responses. Could you please elaborate? Thanks! Janh On Thu, Nov 29, 2018 at 6:45 PM Bert Gunter wrote: > ... but as Duncan poi

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

2018-11-29 Thread Bert Gunter
... but as Duncan pointed out already, I believe, a proportion **is** a mean -- of 0/1 responses. Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Thu, Nov 29,

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

2018-11-29 Thread Janh Anni
Hi Rui, Thanks a lot for responding and I apologize for my late response. I tried using the *boot.two.per* function in the wBoot package which stated that it could bootstrap 2-sample tests for both means and proportions but it turned out that it only works for the mean. Thanks again, Janh On We

[R] help with line graphs - rather lengthy to explain need

2018-11-29 Thread Robert D. Bowers M.A.
I am trying to figure out the best way to organize and plot data generated by a Excel spreadsheet (one driving a sample turntable and collecting optical spectra). The output of the equipment and software is an excel spreadsheet with sample numbers in the first row, and in the first column ther

Re: [R] rmarkdown

2018-11-29 Thread Bert Gunter
1. What error? 2. This is the r-help list. RStudio is a separate product. Requests for help in RStudio should be directed to their lists. Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom

[R] rmarkdown

2018-11-29 Thread Dennis Weygand
When I try to create an rmarkdown file in Rstudio, I get the error below. What am I doing wrong? Sent from Mail for Windows 10 __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do r

Re: [R] Drawing a random number

2018-11-29 Thread William Dunlap via R-help
sample( setdiff(10:1000, Vec), size=1) Also, note that as.integer(runif(1, min, max)) will almost never return max. Bill Dunlap TIBCO Software wdunlap tibco.com On Thu, Nov 29, 2018 at 11:14 AM Christofer Bogaso < bogaso.christo...@gmail.com> wrote: > Hi, > > I would like to draw an Integer fr

[R] Drawing a random number

2018-11-29 Thread Christofer Bogaso
Hi, I would like to draw an Integer from a range of [10, 1000] inclusive, however that random integer should be outside of a pre-defined vector of integers. Let say I draw an integer as below as.integer(runif(1, 10, 1000)) and my pre-defined vector is Vec = c(563, 453, 897, 567) The policy is

Re: [R] Calculating a P for trend

2018-11-29 Thread Bert Gunter
I would suggest that if at all possible, you find a local statistician (your instructor??) with whom to consult. Much of what you are doing appears likely to result in irreproducible nonsense. This list is concerned with R programming, not statistics, although they sometimes do intersect. So I thi

Re: [R] Correct x-axis of two in one graph

2018-11-29 Thread Ogbos Okike
Dear Petr, Thank you so much for your contribution. Let me show you what I have please. I am attaching two plots. The first (twoineone) is my own while the second (testrun) is plotted with the code you send. The first is closer to my interest. The major problem I have is the date. Those were se

[R] Calculating a P for trend

2018-11-29 Thread Lisa van der Burgh
Hi all, I have a question about calculating a P for trend on my data. Let�s give an example that is similar to my own situation first: I have a continuous outcome, namely BMI. I want to investigate the effect of a specific medicine, let�s call it MedA on BMI. MedA is a variable that is catego

Re: [R] Correct x-axis of two in one graph

2018-11-29 Thread PIKAL Petr
Hi If I understand correctly you want Li and CR appear in one plot with the same x axis. Although it is not usually recommended you could use twoord.plot from plotrix or undocumented code below. plot.yy <- function (x, yright, yleft, yleftlim = NULL, yrightlim = NULL, xlab = NULL, yylab = li

[R] Correct x-axis of two in one graph

2018-11-29 Thread Ogbos Okike
Dear Contributors, I have a data of the form: 4 8 10 8590 12516 4 8 11 8641 98143 4 8 12 8705 98916 4 8 13 8750 89911 4 8 14 8685 104835 4 8 15 8629 121963 4 8 16 8676 77655 4 8 17 8577 81081 4 8 18 8593 83385 4 8 19 8642 112164 4 8 20 8708 103684 4 8 21 8622 83982 4 8 22 8593 75944 4 8 23 8600 97