Hi everyone,
I'm working on PISA 2012 data and running into a very similar problem with svyset described as below, posted by Laura back in 2015.
The usual svyset command for PISA that I have found are usually performed is the following using the students' weights "w_fstuwt"
Code:
svyset [pweight=w_fstuwt], brr(w_fstr*) vce(brr) fay(.5) mse
This code is taking into accound the students' weights, but what should I do in order to add a structure including also the school level? Students are nested into schools, which in PISA have also their own weights. In order to syvset the data including the schools I have found the following code:
Code:
svyset schoolid [pw=w_fstuwt], brr(w_fstr*) vce(brr) fay(.5) mse
However, in this last code I wonder why the school weights (w_fschwt) are not integrated.
I have tried the following but it doesn't work for me with my Stata 12.1 version:
Code:
svyset schoolid, weight(w_fschwt) || _n, weight(w_fstuwt)
I get the following error message:
Code:
option weight() not allowed
Of course I would also like to svyset my data including the specificities of PISA (brr(w_fstr*) vce(brr) fay(.5) mse). Reading the svyset help for Stata 12.1 and taking also a look at the examples, I couldn't find anywhere in the syntaxis where to put the schools' weights in the svyset command.
I wonder if you could give me a hint on how to proceed with my code in order to svyset the data in order to include the PISA weighting scheme correctly, including schools and their weights.
M-
I'm working on PISA 2012 data and running into a very similar problem with svyset described as below, posted by Laura back in 2015.
The usual svyset command for PISA that I have found are usually performed is the following using the students' weights "w_fstuwt"
Code:
svyset [pweight=w_fstuwt], brr(w_fstr*) vce(brr) fay(.5) mse
This code is taking into accound the students' weights, but what should I do in order to add a structure including also the school level? Students are nested into schools, which in PISA have also their own weights. In order to syvset the data including the schools I have found the following code:
Code:
svyset schoolid [pw=w_fstuwt], brr(w_fstr*) vce(brr) fay(.5) mse
However, in this last code I wonder why the school weights (w_fschwt) are not integrated.
I have tried the following but it doesn't work for me with my Stata 12.1 version:
Code:
svyset schoolid, weight(w_fschwt) || _n, weight(w_fstuwt)
I get the following error message:
Code:
option weight() not allowed
Of course I would also like to svyset my data including the specificities of PISA (brr(w_fstr*) vce(brr) fay(.5) mse). Reading the svyset help for Stata 12.1 and taking also a look at the examples, I couldn't find anywhere in the syntaxis where to put the schools' weights in the svyset command.
I wonder if you could give me a hint on how to proceed with my code in order to svyset the data in order to include the PISA weighting scheme correctly, including schools and their weights.
M-
Comment