<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Marginal effects with multiple imputed and bootstrapped data in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/390222#M20343</link>
    <description>&lt;P&gt;In order to use Proc MIANALYZE to combine the estimates, you would also need to have a standard error of the marginal effect (or some measure of variation). &amp;nbsp;I suppose this could be done using the Delta Method, but I do not know of any published examples where someone has done this.&lt;/P&gt;</description>
    <pubDate>Wed, 23 Aug 2017 13:15:36 GMT</pubDate>
    <dc:creator>SAS_Rob</dc:creator>
    <dc:date>2017-08-23T13:15:36Z</dc:date>
    <item>
      <title>Marginal effects with multiple imputed and bootstrapped data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/389966#M20317</link>
      <description>Dear all,&lt;BR /&gt;I need to calculate the average marginal effects for some logistic regression models im running. I use proc surveylogistic because my data must be bootstrapped and I was able to run marginal effects for some models. In other models where I have to impute data, I use proc surveylogistic followed by proc analyze.. I'm at a lost as to how I can calculate the marginal effects of the final estimates.&lt;BR /&gt;&lt;BR /&gt;If anyone has any ideas please let me know. Thanks in advance!</description>
      <pubDate>Tue, 22 Aug 2017 18:21:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/389966#M20317</guid>
      <dc:creator>Alice86</dc:creator>
      <dc:date>2017-08-22T18:21:31Z</dc:date>
    </item>
    <item>
      <title>Re: Marginal effects with multiple imputed and bootstrapped data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/390222#M20343</link>
      <description>&lt;P&gt;In order to use Proc MIANALYZE to combine the estimates, you would also need to have a standard error of the marginal effect (or some measure of variation). &amp;nbsp;I suppose this could be done using the Delta Method, but I do not know of any published examples where someone has done this.&lt;/P&gt;</description>
      <pubDate>Wed, 23 Aug 2017 13:15:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/390222#M20343</guid>
      <dc:creator>SAS_Rob</dc:creator>
      <dc:date>2017-08-23T13:15:36Z</dc:date>
    </item>
    <item>
      <title>Re: Marginal effects with multiple imputed and bootstrapped data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/391922#M20451</link>
      <description>&lt;P&gt;Thanks a lot for your response Rob!&lt;/P&gt;&lt;P&gt;I essentially followed this step from SAS support (&lt;A href="http://support.sas.com/kb/22/604.html" target="_blank"&gt;http://support.sas.com/kb/22/604.html&lt;/A&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Marginal effects using results from PROC LOGISTIC&lt;/P&gt;&lt;P&gt;To compute the marginal effects using results from a model fit with PROC LOGISTIC (or other modeling procedure), include an ODS OUTPUT statement to write the ParameterEstimates table to a data set. Also specify the OUTPUT statement to save the predicted probabilities for a logistic model (use the P= option), or the &lt;STRONG&gt;x&lt;/STRONG&gt;'&lt;STRONG&gt;b&lt;/STRONG&gt; values for a probit model (use the XBETA= option) to a data set.&lt;/P&gt;&lt;PRE&gt;      proc logistic data=remiss;
        model remiss(event="1")=blast smear;
        ods output parameterestimates=logparms;
        output out=outlog p=p;
        run;&lt;/PRE&gt;&lt;P&gt;Use PROC TRANSPOSE to arrange the parameter estimates as a row and rename them so as not to conflict with the original variable names.&lt;/P&gt;&lt;PRE&gt;      proc transpose data=logparms out=tlog (rename=(blast=tblast smear=tsmear));
        var estimate;
        id variable;
        run;&lt;/PRE&gt;&lt;P&gt;Then use a DATA step to combine the parameter estimates and OUT= data sets and compute the marginal effects for each observation in the original data. Only the marginal effects for the response level representing the event of interest (REMISS=1) are computed below. The marginal effect for REMISS=0 could be similarly computed.&lt;/P&gt;&lt;PRE&gt;      data outlog;
        if _n_=1 then set tlog;
        set outlog;
        MEffBlast = p*(1-p)*tblast;
        MEffSmear = p*(1-p)*tsmear;
        run;
      proc print noobs;
        var smear blast MEff:;
        run;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used mianalyze to get the appropriate standard errors but used the imputed runs to calculate the average marginal effects &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;</description>
      <pubDate>Wed, 30 Aug 2017 16:09:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Marginal-effects-with-multiple-imputed-and-bootstrapped-data/m-p/391922#M20451</guid>
      <dc:creator>Alice86</dc:creator>
      <dc:date>2017-08-30T16:09:29Z</dc:date>
    </item>
  </channel>
</rss>

