Hello everyone,
I am brand new to Stata, so apologies if my question seems easy to some of you.
I have the following variables:
School: an encoded variable ranging from 1-13 for different school names
Jobs: a dummy variable with 0= no job, 1=job
Sex: a second variable with 1= M, 2= F.
I want to classify how the school impacts the job search, for males and females. To do this, I want to make two horizontal bar graphs with blue bars for males, red for women, and for every categories of schools: one graph for Job Yes and one graph for Job No.
I manage to get what I want with this command:
and I get this "nice" graph:

Now, since the orders of magnitude are very different, I don't see anything in the second part of the graph. So I want just to split the two graphs, to make the bars visibles for Job too.
If I simply do:
I get this, which is not exactly what I want cause I don't need all the M F, I just would like a legend as in the previous graph.

And if I do
, then is completely not what I want:

Where am I wrong?
Thank you to anyone who can help!!
I am brand new to Stata, so apologies if my question seems easy to some of you.
I have the following variables:
School: an encoded variable ranging from 1-13 for different school names
Jobs: a dummy variable with 0= no job, 1=job
Sex: a second variable with 1= M, 2= F.
I want to classify how the school impacts the job search, for males and females. To do this, I want to make two horizontal bar graphs with blue bars for males, red for women, and for every categories of schools: one graph for Job Yes and one graph for Job No.
I manage to get what I want with this command:
Code:
graph hbar (percent), over(Sex) over(School) over(Jobs)
Now, since the orders of magnitude are very different, I don't see anything in the second part of the graph. So I want just to split the two graphs, to make the bars visibles for Job too.
If I simply do:
Code:
graph hbar (percent) if Jobs==1, over(Sex) over(School)
And if I do
Code:
graph hbar (percent) School if Jobs==1, over(Sex)
Where am I wrong?
Thank you to anyone who can help!!
Comment