Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem with the power oneslope command

    Hi!

    I want to do a power analysis for a slope test in my linear regression, the command I have tried to run is:

    power oneslope 0, n(10392) power(0.80) sdx(1.1) sdy(1.16) alpha(0.01)

    but this does not work and I get the following message: "failure to compute effect size; The power function could not be evaluated at the initial values."

    I think I have figured out that my problem is that my sample size is too high (n=10392), this since the command works fine up to n(4300).

    Does anyone know why the command does not work with higher sample sizes, or have I misinterpreted n here? In the description is says "n=sample size; required to compute power or effect size"

    Best regards, Linda


  • #2
    Welcome to Statalist. You didn't get a quick response. You'll increase your chances of a useful answer by following the FAQ on asking questions - provide Stata code in code delimiters, readable Stata output, and sample data using dataex. Being able to replicate your problem is extremely helpful in diagnosing data-related problems.

    I don't work with power calculations, but with 10,000 observations, I doubt if you have power problems. Check the power with the 4300 observations - you should have lots of power for any normal criterion, and moving to 10,000 just gives you more power.

    Comment

    Working...
    X