Suppose the dataset contains a subject-specific variable "earnings". All subjects are grouped into groups, let's say industries. How can I now use xtile to split my data into quintiles on the (higher) industry level? As an example, suppose 1.564 workers work in 20 different industries - in the end, there should be 4 industries in each quintile based on the average earnings within these industries (no matter how many workers are in each industry).
-
Login or Register
- Log in with
Comment