Announcement

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

  • Multiple Imputation MI

    Hi all ,

    Background:

    I have a dataset with 698 participants. I'm interested in doing multivariate regression analysis.

    I have 24 potential covariates (4 of them are continuous, 13 binomial, 7 categorical), 3 dependent variables (continuous: PL, VS, CE) and 1 independent variable (categorical - 6 categories; traj_alcohol). I have missing data on some of my variables (i.e., my potential covariates). I would like to perform multiple imputations and also to conduct univariate analyses with my potential covariates, DV and IV to know which one to include in my final regression model.

    My two questions are:

    1. I have used a chained impuattion method but get an error message and I'm not too sure how to handle it.

    Command: mi impute chained (regress) mat_ment_health parity folate fad (logit) pregnancy_planning SRI preeclampsia preterm SGA drug child_sex DASS_stress DASS_depr DASS_anx antidep_combined post_smoking (mlogit) psy breastfeed parenting pren_smoking BMI diet ax = traj_alcohol, add(1)

    Error: Performing chained iterations ...
    mi impute logit: perfect predictor(s) detected
    Variables that perfectly predict an outcome were detected when logit executed on the observed data. First, specify mi
    impute's option noisily to identify the problem covariates. Then either remove perfect predictors from the model or
    specify mi impute logit's option augment to perform augmented regression; see The issue of perfect prediction during
    imputation of categorical data in [MI] mi impute for details.
    error occurred during imputation of mat_ment_health parity folate fad pregnancy_planning SRI preeclampsia preterm SGA drug
    DASS_stress DASS_depr DASS_anx antidep_combined post_smoking psy breastfeed parenting BMI diet ax on m = 41
    r(498);


    2. Should I impute before or after doing my univariate analyses?

    Thank you!
    Last edited by Garance Delagneau; 08 Jul 2021, 01:35.

  • #2
    re: your first question - your situation is not entirely clear to me but it appears you want to add the "augment" option; see
    Code:
    help mi_impute_chained
    your second question is entirely unclear: what "univariate analyses" are you referring to?

    Comment


    • #3
      Thank you that worked!
      I'm referring to correlations, chi-square analyses, or regression depending on whether my variables are continuous or categorical (i.e., a chi-square between two categorical variables; regression between a dependent and categorical variables, and correlations between two continuous variables). I want to do these analyses to see which potential covariates are associated with my IV or DVs to see which ones I should include in my final multivariate regression analysis.

      Comment


      • #4
        Sorry for all the questions, but I'm also wondering if I should include my DVs and IV in the registration and imputation steps, and participants with imputed outcomes in the final analyses. I found contradictory information on different papers
        Attached Files
        Last edited by Garance Delagneau; 08 Jul 2021, 16:15.

        Comment


        • #5
          (I'm new to stata and multiple imputations so I'm a bit lost)
          Last edited by Garance Delagneau; 08 Jul 2021, 16:16.

          Comment


          • #6
            I also have this error message that keeps popping up:
            variable name: missing imputed values produced
            This may occur when imputation variables are used as independent variables or when independent variables contain missing values. You can specify
            option force if you wish to proceed anyway.

            When I remove that variable from the model, I have a similar message with another variable.

            This is my entire code:
            mi set mlong

            mi register imputed post_smoking preeclampsia preterm pregnancy_planning DASS_stress DASS_anx DASS_depr parity parenting diet mat_ment_health folate fad ethnicity psy breastfeed antidep_combined SRI SGA BMI ax drug VS PL CE child_sex pren_smoking traj_alcohol

            mi impute chained (regress) fad mat_ment_health parity folate VS PL CE (logit) ethnicity pregnancy_planning SRI preeclampsia preterm SGA drug DASS_stress DASS_depr DASS_anx antidep_combined post_smoking (mlogit) psy breastfeed parenting BMI diet ax = traj_alcohol child_sex pren_smoking, add(43) augment noisily

            I've attached screenshots of the errors and of my variables

            Thank you!
            Attached Files

            Comment

            Working...
            X