<?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 Plot distribution of propensity score after weighting in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/Plot-distribution-of-propensity-score-after-weighting/m-p/928905#M24641</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I’ve run a propensity score analysis with inverse probability of treatment weights (IPW) using SAS PROC CAUSALTRT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to plot the logit of the propensity score &lt;U&gt;&lt;STRONG&gt;after&lt;/STRONG&gt; &lt;/U&gt;IPW, but can’t figure out how to weight the propensity scores in the code I’m using to generate the plot. Example code &lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatgraph/n1nh9dhh759jrvn124sn8nn78fv5.htm" target="_self"&gt;from SAS&lt;/A&gt; included below:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc template;
  define statgraph densityplot;
    begingraph;
      entrytitle "Highway Mileage Distribution by Origin";
      layout overlay /
        xaxisopts=(griddisplay=on
          gridattrs=(color=lightgray pattern=dot))
        yaxisopts=(griddisplay=on
          gridattrs=(color=lightgray pattern=dot));
        densityplot mpg_highway / name="densityplot" group=origin;
        discretelegend "densityplot" / title="Origin:";
      endlayout;
    endgraph;
  end;
run;

proc sgrender template=densityplot data=sashelp.cars;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I have seen papers which use IPW and report the propensity score graphically before &lt;U&gt;&lt;STRONG&gt;and after&lt;/STRONG&gt;&lt;/U&gt; IPW. I assume these researchers have weighted the propensity score in the after plot, but I don't understand how to achieve this, or if this is the correct approach to generate the propensity score plot &lt;U&gt;&lt;STRONG&gt;after IPW&lt;/STRONG&gt;&lt;/U&gt;?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In my output, I have a propensity score variable and the IPW variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help/advice would be greatly appreciated,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 18 May 2024 12:33:54 GMT</pubDate>
    <dc:creator>Epi_Stats</dc:creator>
    <dc:date>2024-05-18T12:33:54Z</dc:date>
    <item>
      <title>Plot distribution of propensity score after weighting</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Plot-distribution-of-propensity-score-after-weighting/m-p/928905#M24641</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I’ve run a propensity score analysis with inverse probability of treatment weights (IPW) using SAS PROC CAUSALTRT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to plot the logit of the propensity score &lt;U&gt;&lt;STRONG&gt;after&lt;/STRONG&gt; &lt;/U&gt;IPW, but can’t figure out how to weight the propensity scores in the code I’m using to generate the plot. Example code &lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatgraph/n1nh9dhh759jrvn124sn8nn78fv5.htm" target="_self"&gt;from SAS&lt;/A&gt; included below:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc template;
  define statgraph densityplot;
    begingraph;
      entrytitle "Highway Mileage Distribution by Origin";
      layout overlay /
        xaxisopts=(griddisplay=on
          gridattrs=(color=lightgray pattern=dot))
        yaxisopts=(griddisplay=on
          gridattrs=(color=lightgray pattern=dot));
        densityplot mpg_highway / name="densityplot" group=origin;
        discretelegend "densityplot" / title="Origin:";
      endlayout;
    endgraph;
  end;
run;

proc sgrender template=densityplot data=sashelp.cars;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I have seen papers which use IPW and report the propensity score graphically before &lt;U&gt;&lt;STRONG&gt;and after&lt;/STRONG&gt;&lt;/U&gt; IPW. I assume these researchers have weighted the propensity score in the after plot, but I don't understand how to achieve this, or if this is the correct approach to generate the propensity score plot &lt;U&gt;&lt;STRONG&gt;after IPW&lt;/STRONG&gt;&lt;/U&gt;?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In my output, I have a propensity score variable and the IPW variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help/advice would be greatly appreciated,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 18 May 2024 12:33:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Plot-distribution-of-propensity-score-after-weighting/m-p/928905#M24641</guid>
      <dc:creator>Epi_Stats</dc:creator>
      <dc:date>2024-05-18T12:33:54Z</dc:date>
    </item>
  </channel>
</rss>

