SAS Beginner here.
I have a table counting the number of patents an inventor makes across their career.
ID | Year | Patents
1 1990 1
1 1991 0
1 1992 2
1 1993 0
1 1994 1
2 1975 1
2 1976 0
... ... ...
I want to add a variable called "Past Inventions" that counts all the inventors Patents. So the resulting table would be...
ID | Year | Patents | Past_Inventions
1 1990 1 1
1 1991 0 1
1 1992 2 3
1 1993 0 3
1 1994 1 4
2 1975 1 1
2 1976 0 1
... ... ... ...
How can I solve this using SAS?