Announcement

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

  • Questions on mcartest

    Hello,

    I am trying to test if my data are missing completely at random (MCAR) by using the mcartest command, a user generated command. I have read the article Little’s test of missing completely at random (By Cheng Li, The Stata Journal (2013) 13, Number 4, pp. 795–809).

    I do have a few questions on how to use the mcartest:

    1. In the article, it says the syntax is:
    Code:
    mcartest depvars
    However, my impression is that when it says "depvars" it is NOT referring to the variables that will be dependent variables in your subsequent analysis, but actually the variables that you are interested in testing are MCAR. In my case, I only have missing values for my independent variables so should I put those where depvars go in the syntax?

    2. For covariate dependent missingness, it says to use the syntax,

    Code:
    mcartest depvars = indepvars
    My understanding is that the independent variables for this command are your covariates that do NOT have missing values.

    3. Can you only test if continuous variables are MCAR using Little's test?

    Many thanks,
    Alyssa

  • #2
    Alyssa:
    1) Correct:
    Code:
    mcartest <yourindependentvariables>
    2) Correct:
    Code:
    use bloodtest
    mcartest chol trig diasbp sysbp = weight height exercise i.age i.female i.alcohol i.smoking
    
    Little's CDM test
    
    Number of obs       = 371
    Chi-square distance = 141.1465   
    Degrees of freedom  = 140
    Prob > chi-square   = 0.4569
    3) No, as you can see from the following toy-example:
    Code:
    use "C:\Program Files (x86)\Stata15\ado\base\a\auto.dta"
    clonevar foreign_1=foreign
    replace foreign_1=. in 2/7
    mcartest foreign_1 rep78
    note: 2 observations omitted from EM estimation because of all imputation variables missing
    
    Little's MCAR test
    
    Number of obs       = 72
    Chi-square distance = 0.1074     
    Degrees of freedom  = 2
    Prob > chi-square   = 0.9477
    Kind regards,
    Carlo
    (Stata 18.0 SE)

    Comment


    • #3
      Carlo, Can you help me understand the validity behind using Little's test on binary and categorical variables?

      I see that mcartest can be applied to variables that are binaries (foreign) or categorical (if, for example, you do not declare a categorical variables as one using i.make), but the Stata Journal article that introduces mcartest states that "When the normality is not satisfied, Little’s test still works in the asymptotic sense for quantitative random vectors yi’s but is not suitable for categorical variables (Little 1988)." https://journals.sagepub.com/doi/pdf...867X1301300407

      Is there a way to implement Little's test for categorical missing variables, or an alternate approach for categorical variables in Stata that similarly attempts to help a researcher understand whether making a MAR assumption is wildly inappropriate?

      Comment


      • #4
        Alice:
        https://www.crcpress.com/Flexible-Im.../9781138588318 provides some hints on imputing categorical variables at pages 87-91.
        Kind regards,
        Carlo
        (Stata 18.0 SE)

        Comment

        Working...
        X