<?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: Assessing Balance after IPTW in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/748221#M36397</link>
    <description>&lt;P&gt;As&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13684"&gt;@Rick_SAS&lt;/a&gt;&amp;nbsp; pointed out, the PSMATCH procedure only supports binary treatment variables, and all the balance diagnostics it produces are informed by this condition. Namely, all the balance diagnostics are for comparing two groups, a treatment level to a control level.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For inverse probability weighting, you in theory could try to use multiple runs of PROC PSMATCH to generate separate high-low and high-no comparisons. You would have to subset the data for each call, but the real trick to doing so would be appropriately modifying the input “propensity score” values so they result in the appropriate weight. This would require being familiar with 1) what those appropriate weights are 2) how PROC PSMATCH computes inverse probability weights from the input propensity scores, &lt;A href="https://go.documentation.sas.com/doc/en/statug/15.2/statug_psmatch_details08.htm#statug.psmatch.psmatewgt" target="_self"&gt;as described in the documentation&lt;/A&gt;, and 3) being aware of the fact that PROC PSMATCH assumes the value of the variable listed in the PS= option is always the predicted probability of receiving the designated treatment level (the TREATED= level). What the appropriate modification would be then depends on if you’re interested in estimating the ATE or ATT (note by default PROC PSMATCH uses IPTW ATT weights). One issue you might run into with this approach is if the modified propensity score values don’t result in any overlap between the treatment conditions, in which case PROC PSMATCH will return an error. You would also want to make sure ALLOBS support region is used (which is the default PROC PSMATCH uses for inverse probability weighting) so you don’t end up excluding data unexpectedly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All that said, what is probably easier is to just compute the appropriate IPW weights directly in a bit of data step code and then produce your own weighted diagnostics using PROC SGPLOT and PROC FREQ. Would probably be much less error prone.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 15 Jun 2021 20:40:38 GMT</pubDate>
    <dc:creator>MichaelL_SAS</dc:creator>
    <dc:date>2021-06-15T20:40:38Z</dc:date>
    <item>
      <title>Assessing Balance after IPTW</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/747978#M36395</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a three level treatment variable (no dose, low dose, and high dose) and I am trying to assess covariate balance after IPTW. I used the following code (adapted from codes in this document:&amp;nbsp;&lt;A href="https://www.lexjansen.com/wuss/2017/175_Final_Paper_PDF.pdf" target="_blank" rel="noopener"&gt;https://www.lexjansen.com/wuss/2017/175_Final_Paper_PDF.pdf)&lt;/A&gt;, however, I am getting an error that the response variable needs to be binary.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;proc psmatch data=mydata;
class gender maritalstatus education employment;
psdata treatvar=mytreatment(Treated='High') ps=stabilizedps;
assess ps var=(age gender maritalstatus education employment symptomscores) / plots=all;
run;&lt;/PRE&gt;&lt;P&gt;Does anyone know how I can assess balance after IPTW for a three-level treatment variable?&lt;/P&gt;&lt;P&gt;Thank you!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Jun 2021 12:36:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/747978#M36395</guid>
      <dc:creator>SD29</dc:creator>
      <dc:date>2021-06-15T12:36:12Z</dc:date>
    </item>
    <item>
      <title>Re: Assessing Balance after IPTW</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/748206#M36396</link>
      <description>&lt;P&gt;The error message is because the documentation for the PSDATA statement&lt;/P&gt;
&lt;P&gt;&lt;A href="https://go.documentation.sas.com/doc/en/pgmsascdc/v_013/statug/statug_psmatch_syntax09.htm" target="_blank"&gt;SAS Help Center: PSDATA Statement&lt;/A&gt;&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;says:&lt;/P&gt;
&lt;P class="xisDoc-paragraph"&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="aa-options"&gt;
&lt;DL class="aa-options"&gt;
&lt;DT&gt;&lt;SPAN class=" aa-term "&gt;TREATVAR=&lt;SPAN class=" aa-argument"&gt;treatvar&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&amp;lt;&lt;SPAN class=" aa-lparen"&gt;(&lt;/SPAN&gt;&lt;SPAN class=" aa-keyword"&gt;TREATED&lt;/SPAN&gt;='&lt;SPAN class=" aa-argument"&gt;level&lt;/SPAN&gt;'&amp;nbsp;|&amp;nbsp;&lt;SPAN class=" aa-argument"&gt;keyword&lt;/SPAN&gt;&lt;SPAN class=" aa-rparen"&gt;)&lt;/SPAN&gt;&amp;gt;&lt;/SPAN&gt;&lt;/DT&gt;
&lt;DD&gt;
&lt;P class="xisDoc-paraSimpleFirst"&gt;names the treatment indicator variable,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=" aa-argument"&gt;treatvar&lt;/SPAN&gt;, which must be &lt;FONT color="#FF0000"&gt;a binary classification variable&lt;/FONT&gt; that is specified in the CLASS statement.&lt;/P&gt;
&lt;P class="xisDoc-paraSimple"&gt;The TREATED= suboption specifies the treated level for &lt;FONT color="#FF0000"&gt;the binary treatment variable&lt;/FONT&gt;.&lt;/P&gt;
&lt;P class="xisDoc-paraSimple"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="xisDoc-paraSimple"&gt;I don't know the answer to your question, but&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/256681"&gt;@MichaelL_SAS&lt;/a&gt;&amp;nbsp;wrote a comment that might be related in another thread. Maybe it will be relevant for you:&amp;nbsp;&lt;A href="https://communities.sas.com/t5/Statistical-Procedures/Coding-ordinal-predictors-in-proc-psmatch/td-p/664366" target="_blank"&gt;Coding ordinal predictors in proc psmatch - SAS Support Communities&lt;/A&gt;&lt;/P&gt;
&lt;/DD&gt;
&lt;/DL&gt;
&lt;/DIV&gt;</description>
      <pubDate>Tue, 15 Jun 2021 19:22:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/748206#M36396</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2021-06-15T19:22:27Z</dc:date>
    </item>
    <item>
      <title>Re: Assessing Balance after IPTW</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/748221#M36397</link>
      <description>&lt;P&gt;As&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13684"&gt;@Rick_SAS&lt;/a&gt;&amp;nbsp; pointed out, the PSMATCH procedure only supports binary treatment variables, and all the balance diagnostics it produces are informed by this condition. Namely, all the balance diagnostics are for comparing two groups, a treatment level to a control level.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For inverse probability weighting, you in theory could try to use multiple runs of PROC PSMATCH to generate separate high-low and high-no comparisons. You would have to subset the data for each call, but the real trick to doing so would be appropriately modifying the input “propensity score” values so they result in the appropriate weight. This would require being familiar with 1) what those appropriate weights are 2) how PROC PSMATCH computes inverse probability weights from the input propensity scores, &lt;A href="https://go.documentation.sas.com/doc/en/statug/15.2/statug_psmatch_details08.htm#statug.psmatch.psmatewgt" target="_self"&gt;as described in the documentation&lt;/A&gt;, and 3) being aware of the fact that PROC PSMATCH assumes the value of the variable listed in the PS= option is always the predicted probability of receiving the designated treatment level (the TREATED= level). What the appropriate modification would be then depends on if you’re interested in estimating the ATE or ATT (note by default PROC PSMATCH uses IPTW ATT weights). One issue you might run into with this approach is if the modified propensity score values don’t result in any overlap between the treatment conditions, in which case PROC PSMATCH will return an error. You would also want to make sure ALLOBS support region is used (which is the default PROC PSMATCH uses for inverse probability weighting) so you don’t end up excluding data unexpectedly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All that said, what is probably easier is to just compute the appropriate IPW weights directly in a bit of data step code and then produce your own weighted diagnostics using PROC SGPLOT and PROC FREQ. Would probably be much less error prone.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 15 Jun 2021 20:40:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Assessing-Balance-after-IPTW/m-p/748221#M36397</guid>
      <dc:creator>MichaelL_SAS</dc:creator>
      <dc:date>2021-06-15T20:40:38Z</dc:date>
    </item>
  </channel>
</rss>

