Hi all,
I am trying to create a Table 1 using Medicare claims to compare demographics among people who do and do not have an outcome, acute MI. I am using a file in which there are multiple claims per person. Each person is identified by a ilinkid.
I created a flag using:
egen byte flag = tag(ïlinkid)
I also created two categories of people with and without acute MI. A person who has acute MI is in category hasMI=1, and a person who doesn't is in hasMI=0.
I was wondering if there was any way to use tab along with the demographic category and the flag. For example, I tried: "tab race if hasMI==1, if flag" which does not work. I want my percentages to be based on # people in the cohort, not on the # claims.
I appreciate any help!
Related Posts with Question about using if flag + tab together
Plotting graphs related to synth (synthetic control)Array Folks, I’m trying to plot some graphs related to command synth in Stata, but I’m not succeedin…
Identifying persons with affected parentsHi, A common problem when studying families is to identify offspring with affected parents. The pro…
Positive and Negative DV Values in Panel Data analysis, potential solutionsis it possible to regress a period average of your DV onto annual values of IVs. My DV is Chinese OF…
Analysing Likert scale outcome variable and how to combine questions into oneHello friends I have a challenge analysing likert scale outcome variable. Allow me share full detail…
Wald test for one-sided hypothesis - strict inequalityI am trying to test a one-sided hypothesis after running a regression to see if the sum of two coeff…
Subscribe to:
Post Comments (Atom)
0 Response to Question about using if flag + tab together
Post a Comment