Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Scatter plot with dummy variable

    Hi everyone,

    I have a panel dataset from 1999 to 2020. I also have dummy variable for the incidence of conflict that takes 1 if there's a new or ongoing conflict and 0 otherwise. In addition, I have countries and fractionalization index. I want to create a scatter plot with the average number of civil conflict incidence (y axis) in each country and the average degree of fractionalization (x-axis). How can I do that given that incidence is dummy variable?

    Many thanks,
    Yasmine

  • #2
    Check out the "jitter option" in https://www.stata.com/manuals/g-2graphtwowayscatter.pdf.

    In any case, the row of zero is likely going to be very overwhelming. So, consider other possibilities such as converting the average number of conflicts into ordinal (e.g. 0, 1, 2, 3, 4+, etc.) and plot their fractionalization as a bar graphs.
    Last edited by Ken Chui; 08 May 2022, 10:39.

    Comment

    Working...
    X