Announcement

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

  • t test for two independent gr.

    Hi everyone; I m new on Stata so i had to advise here.

    Two-sample t test with equal variances
    ------------------------------------------------------------------------------
    Group | Obs Mean Std. Err. Std. Dev. [95% Conf. Interval]
    ---------+--------------------------------------------------------------------
    0 | 125 10.63823 .1110408 1.241474 10.41845 10.85801
    1 | 441 10.86407 .0632819 1.328919 10.7397 10.98844
    ---------+--------------------------------------------------------------------
    combined | 566 10.8142 .0551638 1.312388 10.70585 10.92255
    ---------+--------------------------------------------------------------------
    diff | -.2258386 .1327607 -.4866044 .0349272
    ------------------------------------------------------------------------------
    diff = mean(0) - mean(1) t = -1.7011
    Ho: diff = 0 degrees of freedom = 564

    Ha: diff < 0 Ha: diff != 0 Ha: diff > 0
    Pr(T < t) = 0.0447 Pr(|T| > |t|) = 0.0895 Pr(T > t) = 0.9553

    these are my results. so can i say "the mean of 0 is significantly lower than the mean of 1"? it may be a easy question but as i sad i m trying to teach. thx

  • #2
    Gokhan:
    welcome to this forum.
    The first issue here is which test do you prefer? One-sided or two-sided?
    Your statement is correct only if your aim was to calculate a one-sided -ttest-.
    I'd also add that the hypothesis of equal variance seldom holds.
    In addition, as per FAQ:
    1) please use CODE delimiters to share what you typed and what Stata gave you back;
    2) this forum has a longstanding preference for real name and surname. Thanks.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      thx for ur informative back Mr. Lazarro;

      firstly i wrote my real surname but the system did not accept. i will try to change it again.

      i tested equal variance between groups by using "sdtest" command.so here i think the "group 1" samples has significantly higher than "group 0" in terms of mean. so my aim was to calculate one-sided ttest to see my this assumption. Is this the right approach?

      thx again for ur answers,
      kind regards
      gökhan

      Comment


      • #4
        Gokham:
        thanks for clarifying.
        Your description is more complete now and, for what I wrote, your approach is corret.
        However, an additional coment my rest on the different sample sizes between the two groups.
        Eventually, please call me Carlo, just like all on this forum (and many more off) do. Thanks.
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment


        • #5
          thx Carlo, lastly i want to advise one issue. my p value is 0.0447. so i say "group 1" samples has significantly higher than "group 0" in terms of mean. but my confidence interval -.4866044 - .0349272. so it includes 0 (zero). so is this block my comment? can i still make same statement. because i found different sources. some of them say if ur Confidence interval includes 0 there is no significant result. but some sources say it does not mean that ur p value is non significant. i confused

          Comment


          • #6
            Gokhan:
            what Stata reports is the confidence interval consistent with the two-tailed -ttest-, that actualy did not reach statistical significance.
            But you're interested in one-tailed -ttest-, that, in your case, reches statistical significance.
            Simple as that.
            Kind regards,
            Carlo
            (Stata 19.0)

            Comment

            Working...
            X