<?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 Difference-in-differnce with zero inflated data in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Difference-in-differnce-with-zero-inflated-data/m-p/657580#M36210</link>
    <description>&lt;P&gt;Hello everybody,&lt;/P&gt;&lt;P&gt;I did a differnce-in-difference anlysis for in health care expenditures using proc genmod and %NLEstimate. People participating in a stuctured health care programme (Prog=1) were compared to those who do not participate (Prog=0). With data for both groups availabe for 1 year before intervention (post=0) and 1 year after intervention (post=1). The same subjects are measured before and after. The code I used works for the primary outcome "total cost". But now I need to analyse subcategories of costs, additinally (for hospitalisation, drugs,...) and some of these subcategories are zero-inflated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there any option how I can make a DiD anaysis using zero-inflated data?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be greatly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Maggie&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;proc genmod data= cost;
class prog post / ref= first;
model total_cost= prog post prog*post / dist=gamma link=log;
estimate "diff_in_diff" prog*post  1 -1 -1 1;
lsmeans prog*post  / e linik;
lsestimate prog*post "diff_in_diff" 1 -1 -1 1;
store out= gammod;
run; 

data difdif;
input k1-k4;
set=1;
datalines; 
1 -1 -1 1;

%NLEstimate (instore= gammod,
label= Diff in Diff
f=(exp(b_p1+b_p2+b_p4+b_p6) - exp(b_p1-b_p4)) - 
(exp(b_p1+b_p2) - exp(b_p1)), 
title= DiD Totel cost)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jun 2020 15:51:06 GMT</pubDate>
    <dc:creator>mag_newbie</dc:creator>
    <dc:date>2020-06-11T15:51:06Z</dc:date>
    <item>
      <title>Difference-in-differnce with zero inflated data</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Difference-in-differnce-with-zero-inflated-data/m-p/657580#M36210</link>
      <description>&lt;P&gt;Hello everybody,&lt;/P&gt;&lt;P&gt;I did a differnce-in-difference anlysis for in health care expenditures using proc genmod and %NLEstimate. People participating in a stuctured health care programme (Prog=1) were compared to those who do not participate (Prog=0). With data for both groups availabe for 1 year before intervention (post=0) and 1 year after intervention (post=1). The same subjects are measured before and after. The code I used works for the primary outcome "total cost". But now I need to analyse subcategories of costs, additinally (for hospitalisation, drugs,...) and some of these subcategories are zero-inflated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there any option how I can make a DiD anaysis using zero-inflated data?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be greatly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Maggie&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;proc genmod data= cost;
class prog post / ref= first;
model total_cost= prog post prog*post / dist=gamma link=log;
estimate "diff_in_diff" prog*post  1 -1 -1 1;
lsmeans prog*post  / e linik;
lsestimate prog*post "diff_in_diff" 1 -1 -1 1;
store out= gammod;
run; 

data difdif;
input k1-k4;
set=1;
datalines; 
1 -1 -1 1;

%NLEstimate (instore= gammod,
label= Diff in Diff
f=(exp(b_p1+b_p2+b_p4+b_p6) - exp(b_p1-b_p4)) - 
(exp(b_p1+b_p2) - exp(b_p1)), 
title= DiD Totel cost)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jun 2020 15:51:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Difference-in-differnce-with-zero-inflated-data/m-p/657580#M36210</guid>
      <dc:creator>mag_newbie</dc:creator>
      <dc:date>2020-06-11T15:51:06Z</dc:date>
    </item>
  </channel>
</rss>

