similar to: Package for sample size calculation

Displaying 20 results from an estimated 8000 matches similar to: "Package for sample size calculation"

2006 Mar 08
1
power and sample size for a GLM with Poisson response variable
Craig, Thanks for your follow-up note on using the asypow package. My problem was not only constructing the "constraints" vector but, for my particular situation (Poisson regression, two groups, sample sizes of (1081,3180), I get very different results using asypow package compared to my other (home grown) approaches. library(asypow) pois.mean<-c(0.0065,0.0003) info.pois <-
2006 Feb 06
3
power and sample size for a GLM with poisson response variable
Hi all, I would like to estimate power and necessary sample size for a GLM with a response variable that has a poisson distribution. Do you have any suggestions for how I can do this in R? Thank you for your help. Sincerely, Craig -- Craig A. Faulhaber Department of Forest, Range, and Wildlife Sciences Utah State University 5230 Old Main Hill Logan, UT 84322 (435)797-3892
2010 May 06
4
sample size for survival curves
Dear R users, I am not asking questions specifically on R, but I know there are many statistical experts here in the R community, so here it goes my questions: Freedman (1982) propose an approximation of sample size/power calculation based on log-rank test using the formula below (This is what nQuery does): (Z(1-?/side)+Z(power))^2*(hazard.ratio+1)^2 N =
2009 Mar 21
1
Looking for program for sample size determination
we have some initial data from our field sampling. From the means and variances, we see your sampling field is much heterogeneous (not uniform). We are looking for a "R" program for sampling size determination. Right now, we are not good enough to write a whole "R" program, so please help. [[alternative HTML version deleted]]
2010 Nov 08
2
Sample size calculation for differences between two very small proportions (Fisher's exact test or others)?
Hi, I'm try to compute the minimum sample size needed to have at least an 80% of power, with alpha=0.05. The problem is that empirical proportions are really small: 0.00154 in one case and 0.00234. These are the estimated failure proportion of two medical treatments. Thomas and Conlon (1992) suggested Fisher's exact test and proposed a computational method, which according to their table
2012 Mar 28
1
binomial sample size calculation
Hi everyone. I need to do a sample size calculation for a one sample based on a CI interval of +- 5% of the proportion, we expect to have a rate of 0.07 based on similar studies. I have looked at the pwr-package as well as the power.prop.test function, but I can't see how to make either do what I need. Could anyone point me to a function, or explain how to do this will the functions in pwr?
2011 Nov 03
1
non-parametric sample size calculation
Hi, I am trying to estimate the sample size needed for the comparison of two groups on a certain measurement, given some previous data at hand. I find that the data collected does not follow a normal distribution, so I would like to use a non-parametric option for sample size calculation. I found the pwr package but I don't think it has this option and on the internet found that
2011 Nov 14
1
Power analysis and sample size calculation for nonlinear regression
Is there a library that provides power calculation and sample size estimation for nonlinear regression? The task is easy for linear regression with the "pwr" package, but I can't find a method for nonlinear regression (estimated with the "nls" package). -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- Dr. Johannes W. Dietrich, M.D. --
2008 Dec 31
2
Off-topic -- an eye on a stats presentation for clinicians?
I've got a 20 slide Powerpoint set up against the expected day someone says "Mitch, could you talk for a short while to the residents on how to use statistics?" It looks good at this end, but I'd love to get at least one more pair of eyes on it. Any volunteers? -- Due to the recession, requests for instant gratification will be deferred until arrears in scheduled
2009 Sep 30
3
programming to calculate variance
Dear R-user Suppose I have the following data y=c(2,1,5,8,11,3,1,7,50,21,33,7,60) x=data.frame(y) for(i in 4:nrow(x)) x[i,] =var(x[i-3:i-1,]) I'm trying to get a new variable with the variance of the 3 previous values (just an example) and with NA in the three first positions. I know that my for() is wrong but I'm not able to find my error. Any idea? Thanks, Marlene.
2006 Nov 13
3
For MacBook, best way to do R?
I'm getting a MacBook and I'd like to stick with OS X rather than convert it to Linux just yet. However, my main concern is having decent performance. What's my best option: *use the existing binary for R? *compile R fresh under OS X? * install Linux and run R under that? Does anyone have any recent experience they can share? Thanks! -- I can answer any question. "I
2000 May 03
1
Bug report -- 1.0.1, HP-UX (PR#532)
Dear R folks, Additional problem... bug.report() failed, so am sending it from another mailer. The file it generated is appended. Thanks Russ -- Russell V. Lenth -- Department of Statistics & Actuarial Science The University of Iowa -- Iowa City, IA 52242 USA Tel (319)335-0814 -- FAX (319)335-3017 mailto:Russell-Lenth@uiowa.edu - http://www.stat.uiowa.edu/~rlenth/ ===== R.bug.report
2020 Nov 04
2
sprintf, check number of parameters
Dear Tomas,Thank you.Regarding the "unnumbered" arguments, i.e. sprintf('%f %f', 1, 2, 3). This was the case I wanted to report, here a warning can be very useful.Regarding the "numbered" arguments, that is, sprintf('%$1f %$3f', 1, 2, 3). Here, omission of an argument might be intended, for example, in an application with support for multiple languages.
2008 Nov 25
2
Statistical question: one-sample binomial test for clustered data
Dear list, I hope the topic is of sufficient interest, because it is not R-related. I have N=100 yes/no-responses from a psychophysics paradigm (say Y Yes and 100-Y No-Responses). I want to see whether these yes-no-responses are in line with a model predicting a certain amount p of yes-responses. Standard procedure would be a one-sample binomial test for the observed proportion, chi?(1 df) =
2012 Jun 24
2
Power calculation using pwr.t.test()
Dear R experts, I have conducted a power calculation in order to estimate the number of subjects needed to detect an effect size of d=0.28 (cohen's d) for a difference between two independent groups (alpha level should be 0.05 and the effect should be detected with 80% probability). The results from the code below indicates that I would need n=400 subjects (200 in each group). This is seems
2017 Sep 02
2
Strange lazy evaluation of default arguments
Another way to avoid the problem is to not redefine variables that are arguments. E.g., > Su3 <- function(u=100, l=u, mu=0.53, sigma2=4.3^2, verbose) { if (verbose) { print(c(u, l, mu)) } uNormalized <- u/sqrt(sigma2) lNormalized <- l/sqrt(sigma2) muNormalized <- mu/sqrt(sigma2) c(uNormalized, lNormalized, muNormalized) } > Su3(verbose=TRUE)
2017 Sep 02
6
Strange lazy evaluation of default arguments
Dear R developers, sessionInfo() below Please have a look at the following two versions of the same function: 1. Intended behavior: > Su1 = function(u=100, l=u, mu=0.53, sigma2=4.3^2) + { + print(c(u, l, mu)) # here, l is set to u?s value + u = u/sqrt(sigma2) + l = l/sqrt(sigma2) + mu = mu/sqrt(sigma2) + print(c(u, l, mu)) + } > > Su1() [1] 100.00 100.00 0.53 [1]
2010 Jun 10
1
Power calculation
Hello, Is there any R function which does power calculation for unbalanced groups (n1 neq n2)? Since power.t.test has n Number of observations (per group). Many thanks, Samuel [[alternative HTML version deleted]]
2020 Sep 20
2
sprintf, check number of parameters
Dear R developers, I am wondering if this should raise an error or a warning. > sprintf('%.f, %.f', 1, 2, 3) [1] "1, 2" I am aware that R has ?numbered? sprintf arguments (sprintf('%1$.f', ?), and in that case, omissing of specific arguments may be intended. But in the usual syntax, omission of an argument is probably a mistake. Thank you for your consideration.
2004 Sep 20
2
asypow.noncent: how does it work?
I am trying to do power calculations for the proportional odds model using the asypow library. The code noncenta90b10<-asypow.noncent(theta.ha=a9010,info.mat=infomatrixa90b10,constraints=constrt) returns Error in max(..., na.rm = na.rm) : invalid "mode" of argument. the various arguments I've used are: a9010 [,1] [1,] -1.7357568 [2,] -0.1928619 specifying the