How to test The Parallel Trends Assumption when there is a staggered...
Hi. I have 48 weeks of week-level data in an unbalanced panel dataset which tracks the effect of a telemedicine intervention on Covid health outcomes across different states. The telemedicine has a...
View ArticleUsing xtdidregress command with 2 cohorts from different birth years
I am using xtdidregress command in Stata 18.0. Purpose of doing this is to identify the causal effect of an educational program on treated cohort vs control cohort. Treated cohort was born 4 years...
View ArticleAssistance with Implementing Staggered DID for Unbalanced Panel with Repeated...
Hello Stata Community, I am a PhD scholar in finance and would greatly appreciate your help in implementing a staggered Difference-in-Differences (DID) analysis for my dataset. Data ContextPanel...
View Articledid2s: pre-trend tests checking for parallel trend?
Dear all, I am using the command did2s to estimate a two-stage difference-in-difference model. I am looking at the effect on candidates' vote share in 300 municipalities, following the treatment. The...
View Articlecollapse problem
Sorry this should be simple. I have a dataset that I want to collapse. It is proprietary so I can't post it. Here are the commands I entered: . fsum party - partyideology income attend - presapp mip*...
View ArticleCan’t estimate AME of colinear variable used in non-colinear interaction terms
I am analyzing a dataset on removal proceedings adjudicated by the U.S. immigration court system. One of my regressions seeks to analyze the AME of attorney representation by immigrant race and...
View ArticleSum of population
Good day. Please may you assist with syntax on how I can obtain total population for each of the areas (1, 2) for each year. The data is presented as follows: SA2 Year Population Area 123 2019 200 1...
View ArticleEstimating prevalence from a multiple response variable
Hello all, I have a multiple response variable of different methods. I intend to group the responses into two groups of method 1 and method 2 and then estimate the prevalence of method two. Below is...
View Articleadditive group sum & mean
Dear all, Please advise me on how to calculate the additive sum and mean by year, as shown in the snapshot I've pasted below. I appreciate it in advance. Code: * Example generated by -dataex-. For more...
View Articleexploratory factor analysis
how to do factor analysis for 3 dichotomous and 2 ordinal variables?
View Articlevce(robust) in mixed model (MLM)
Hello everyone, I hope you are well. I'm wondering about the mixed models. Here is my order: Code: mixed Qtobin_w mills centBWOMEN c.centBWOMEN#i.quota BoardSize indep CEOChairmanDuality SIZE_w lnAGE...
View ArticleProble with some graphs
Dear all, I'm having some problems with a graph that is generated through a double for. In particular, I'm generating a graph for each of 11 different countries and conditioning the variables to three...
View ArticleHope to get help for dealing with outliers
Dear all, I’m facing an issue and would like your advice. In my regression analysis, county-level population density is the key explanatory variable, and county area is a control variable. I...
View Articleineqdeco for multiple categories (land inequality)?
Dear Statalist Community, I am having trouble calculating the theil index for land inequality using ineqdeco. I want to calculate this index for each of my municipalities. However, for each...
View ArticleReshape: Using previous variable labels to create a new string variable?
Hey everyone, I have the following dataset: Code: * Example generated by -dataex-. For more info, type help dataex clear input str14 Type float(ag1de_Plcyprob ag1de_PlcyForm ag1de_Implemen...
View ArticleAdapting 'xtbcfe' for Dynamic Panel Count Data models (Poisson/Negative...
Dear Statalist members, I am relatively new to Stata and kindly seek your guidance. I am working on a study where my dependent variable, Incident_Count, is a count variable representing monthly...
View ArticleP value in outreg2 statistics
Hi all, My question concerns user-written commands boottest and outreg2. I would like to display the p-value of boottest in the stats() of outreg2 instead of p-values from the user-written reghdfe...
View ArticleI can not calculate the "margin" for one of the terms of an...
Hello, I am looking to model the marginal effect of increasing screen time (ppost_12) on the flourish score. I am looking to model this as a function of sexe/variable "sex5" (for which female = 1 or...
View ArticleDrawing a histogram by different taxes and two dates
Hello Stata users, I have this data at hand: Code: * Example generated by -dataex-. To install: ssc install dataex clear input str44 impot byte(moyenne_2009_2019 anne_2022) "TVA" 4 15 "Autres Impots...
View ArticleHow to average a variable before and after a key event
Dear All, Could you please help me with this problem: how to average the sleep variable t_NREM 5 days before and 5 days after the immunological variable IL1bf (which occurs only occasionally)? There...
View Article