Announcement

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

  • statistical test to compare sensitivities of a diagnostic test in 2 subgroups of a sample population

    Hi all,
    I have a population of 800 individuals and i am using a diagnostic test to diagnose a condition. i have calculated the sensitivity of the test in the over 30 (n=410) and over 40 (n=243) years old individuals and found Sn30+ = 82% and Sn 40+ = 94%. i am wondering if there is a way to statistically compare the 2 sensitivities. Thanks in advance

    stata 16

  • #2
    Abdelilah:
    what follows mighte be helpful:
    Code:
    . 
    . prtesti 100 41 100 30, count
    
    Two-sample test of proportions                     x: Number of obs =      100
                                                       y: Number of obs =      100
    ------------------------------------------------------------------------------
                 |       Mean   Std. err.      z    P>|z|     [95% conf. interval]
    -------------+----------------------------------------------------------------
               x |        .41   .0491833                      .3136024    .5063976
               y |         .3   .0458258                      .2101832    .3898168
    -------------+----------------------------------------------------------------
            diff |        .11   .0672235                     -.0217557    .2417557
                 |  under H0:    .067672     1.63   0.104
    ------------------------------------------------------------------------------
            diff = prop(x) - prop(y)                                  z =   1.6255
        H0: diff = 0
    
        Ha: diff < 0                 Ha: diff != 0                 Ha: diff > 0
     Pr(Z < z) = 0.9480         Pr(|Z| > |z|) = 0.1041          Pr(Z > z) = 0.0520
    
    .
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      thanks Carlo. is the tabi command ok for this analysis.
      Click image for larger version

Name:	statalist exmaple.jpg
Views:	1
Size:	6.3 KB
ID:	1728975
      Code:
      tabi 142 60\ 43 18, chi2
      . tabi 142 60\ 43 18, chi2
      col
      row 1 2 Total
      1 142 60 202
      2 43 18 61
      Total 185 78 263
      Pearson chi2(1) = 0.0009 Pr = 0.977

      Comment


      • #4
        If, as would be the case under ordinary English usage, the over-30 group also includes the over-40 group, then these approaches to testing are not valid. Both -prtest- and -tab- require the samples to be independent. To use them correctly, you need to test the 30-39 group against the over-40 group.

        Comment


        • #5
          My whole idea is to say that if i use my diagnostic tool on the whole sample population the sensitivity of the test is lower lower than ithe sensitivity obtained in over 40 years individuals.

          Comment


          • #6
            Understood, but you cannot do that directly with these statistical tests. These tests, and others like it are predicated on testing independent samples. The results you are seeing are meaningless.

            Now, think more carefully about the logic. Your null hypothesis, that you hope to reject, is that the sensitivity is the same in the entire over-30 population as it is in the over-40 population. Well, that will be true if and only if the sensitivity is the same in the 30-39 population as in the over 40 population. So if you reject the null in the 30-39 vs over 40 population test, you will have also rejected the null that the sensitivity is the same in the entire over-30 group as it is in the over-40 group.

            Statistical comparisons compare mutually exclusive subsets, not subsets with the supersets that contain them.

            There will be nothing wrong, in the end, with showing the sensitivity in the whole sample and the sensitivity in the over-40 subset in your presentation/write-up. But the hypothesis test must be based on a contrast of 30-39 with over 40.

            Comment


            • #7
              Many thanks. understood. I have now split my data into <40 and >=40 and then use tabi

              Comment

              Working...
              X