Dear statalists:
I want to use a mirco sampling data in R,but the package used in R is systemfit which doesn't support sampling weight(in stata,we can use option pweight),so I need to make some transformation to data in advance,. My question is how to transform constants in stata.
In stata,if we want to use mirco sampling data for OLS,we can use this code:
Code:
reg y x [pweight = weight]

*If we don't have constant,this order will be:

reg y x [pweight = weight],nocons

*and we can do it by hand,the next three codes are equal to "reg y x [pweight = weight],nocons"

replace y = y*((weight)^0.5)
replace x = x*((weight)^0.5)
reg y x,noncons
But the constant can't be omitted in regression, I wonder if you can tell how to use pweight by hand with constant in stata.
Many thanks