Dear Statalist forum members,
I've been working for a while trying to solve this problem. Then, I thought that I have invested a lot of time looking for a solution and it's time to ask to this forum how to solve it.
I have a set of variables like this (numbers are irrelevant, just given as an example):
Then, I generate a new variable that is 0 if a value is lower than p50 and 1 if is equal or greater that p50, by year.
And I want to display something like this, with a set of commands (or one command, but I want the table already done). a"year" is p50 of data of that year and below p50 (marked as 0) and b"year" is the same thing but with the data marked with 1:
Asterisks are: ** if p<0.05; * if p<0.1. I get this values from ranksum.
I don't know if I have been clear enough. I hope this helps to see what I am trying to do.
Thank you in advance,
Jose Lorenzo.
I've been working for a while trying to solve this problem. Then, I thought that I have invested a lot of time looking for a solution and it's time to ask to this forum how to solve it.
I have a set of variables like this (numbers are irrelevant, just given as an example):
n | year | v1 | v2 |
1 | 2000 | 4 | 1 |
2 | 2000 | 6 | 2 |
3 | 2000 | 4 | 4 |
4 | 2000 | 8 | 1 |
1 | 2001 | 4 | 4 |
2 | 2001 | 8 | 5 |
3 | 2001 | 6 | 3 |
4 | 2001 | 4 | 2 |
And I want to display something like this, with a set of commands (or one command, but I want the table already done). a"year" is p50 of data of that year and below p50 (marked as 0) and b"year" is the same thing but with the data marked with 1:
a2000 | b2000 | sig2000 | a2001 | b2001 | sig2001 | |
v1 | 4 | 7 | ** | 4 | 7 | ** |
v2 | 1 | 4 | * | 2.5 | 4.5 |
I don't know if I have been clear enough. I hope this helps to see what I am trying to do.
Thank you in advance,
Jose Lorenzo.
Comment