Dear all,
I'm working on a social policy for a job center. We are sending job recommendations to job seekers by mail according to their expected sector or a related sector.
My database looks like :
Each job seekers would receive two mails with two companies recommended. I would like to find a way to re-sort my observations (keeping them sorted by ID) in a way
that minimizes identical successive companies recommended; i.e. in the case above, invert the second obs with the third one in order to get two different companies recommended in the first mail and not the same ones (the first mail recommend the two first companies specific to each job-seekers, the second mail the two following ones, and so on).
Thanks by advance,
Faustin
I'm working on a social policy for a job center. We are sending job recommendations to job seekers by mail according to their expected sector or a related sector.
My database looks like :
ID | sector seek by the ID | Company recommended | sector of the company recommended |
1 | a | x | a |
1 | a | x | a |
1 | a | z | a |
1 | a | y | t |
2 | z | e | r |
2 | z | e | t |
2 | z | e | u |
2 | z | z | v |
Each job seekers would receive two mails with two companies recommended. I would like to find a way to re-sort my observations (keeping them sorted by ID) in a way
that minimizes identical successive companies recommended; i.e. in the case above, invert the second obs with the third one in order to get two different companies recommended in the first mail and not the same ones (the first mail recommend the two first companies specific to each job-seekers, the second mail the two following ones, and so on).
Thanks by advance,
Faustin
Comment