Using Stata for Survey Data Analysis


Example 20. Two-way scatterplot graph


Download 1.39 Mb.
Pdf ko'rish
bet52/61
Sana08.03.2023
Hajmi1.39 Mb.
#1252470
1   ...   48   49   50   51   52   53   54   55   ...   61
Bog'liq
2009 Usingstataforsurveydataanalysis (1)

Example 20. Two-way scatterplot graph 
0
.5
1
6
8
10
6
8
10
Urban
Rural
fo
o
d
sh
a
re
lnpce
Graphs by Stratum
In Example 21, a histogram was created with 20 columns (“bins”) using the command:
histogram lnpce, by(stratum) normal bin(20) 


Minot
 
 
 
 
 
Using Stata for Survey Analysis 
Page 48 
 

Example 21. Histogram of per capita expenditure in Bhutan 
0
.2
.4
.6
4
6
8
10
4
6
8
10
Urban
Rural
Density
normal lnpce
D
e
n
sit
y
lnpce
Graphs by Stratum
In Example 22, the bar graph of average per capita expenditure by stratum (urban/rural) and by sex of 
head of household was created using the command: 
 
graph bar pc_t_mo, over(b21_q1) over(stratum) 
Example 22. Bar chart of per capita expenditure by region  
0
1
,0
0
0
2
,0
0
0
3
,0
0
0
4
,0
0
0
me
a
n
o

p
c_
t_
mo
Urban
Rural
Male
Female
Male
Female


Using Stata for Survey Data Analysis 
 
Minot 
 
Page 49
SECTION 10: REGRESSION ANALYSIS
This section describes the use of Stata to do regression analysis. Regression analysis involves 
estimating an equation that best describes the data. One variable is considered the dependent 
variable, while the others are considered independent (or explanatory) variables. Stata is capable of 
many types of regression analysis and statistical tests. In this section, we touch on only a few of the 
more common commands and procedures. The commands described in this section are: 
regress 
probit 
predict 
test, testparm 
ovtest 
hettest 
svy option 
regress  
This command carries out a regression analysis on the variables specified. Regression analysis 
estimates an equation of “independent” (or “explanatory”) variables that best explains variation in a 
“dependent” variable. This command is used when the dependent variable is a continuous variable. 
The syntax is: 

Download 1.39 Mb.

Do'stlaringiz bilan baham:
1   ...   48   49   50   51   52   53   54   55   ...   61




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling