Ich konstruiere einen Multidimensional Poverty Index (MPI) aus Mikrodaten einer Haushaltsumfrage. Dafür muss ich die Anzahl der Mitarbeiter-Verhältnis (H) und die Intensität der Armut (A), so konnte ich tun: MPI = H * A.Wie konstruiere ich multidimensionalen Armutsindex (MPI) mit Hilfe von svy
Meine Datenbank ist wie folgt aus:
str(base2015)
Classes ‘tbl_df’, ‘tbl’ and 'data.frame': 117939 obs. of 33 variables:
$ X1 : int 1 2 3 4 5 6 7 8 9 10 ...
$ domicilio : num 1.1e+10 1.1e+10 1.1e+10 1.1e+10 1.1e+10 ...
$ agua : int 0 0 6 2 0 0 0 0 0 0 ...
$ ind_agua : int 0 0 1 1 0 0 0 0 0 0 ...
$ esgoto : int 1 1 6 2 1 2 3 5 3 1 ...
$ ind_cond_sanitaria: int 1 1 1 1 1 1 1 1 1 1 ...
...
$ pre_wgt : int 200 200 200 200 200 200 200 200 200 200 ...
$ one : int 1 1 1 1 1 1 1 1 1 1 ...
$ region : int 1 1 1 1 1 1 1 1 1 1 ...
$ c : num 0.2 0.2 0.2 0.3 0.3 0.3 0.2 0.2 0.1 0.1 ...
$ q : num 0 0 0 0 0 0 0 0 0 0 ...
ich schon haben H und A das Umfragepaket benutzt.
#proporção de pobres para região (H)
svyby(~ q , ~ region , n , vartype=c("se","cv","ci"), svymean)
und diese:
# A by Região
# 1-norte 2-nordeste 3-sudeste 4-sul 5-centro-oeste
svyby(~ c , ~ region , subset_q , vartype=c("se","ci","cv"), svymean)
Aber ich weiß nicht, wie das MPI selbst (MPI = H * A) Entnahme der Probe Design Rechnung zu berechnen. Kann mir jemand dabei helfen?
PS: Ich habe versucht, mal das andere, aber ich bin mir nicht so sicher.
#MPI
svyby(~ q , ~ region , n , vartype=c("se","cv","ci"), svymean)*svyby(~ c , ~ region , subset_q , vartype=c("se","ci","cv"), svymean)