i have panel time series.
I want to create a variable that is the difference between the last non-missing value and the first non-missing value.so in this case for Austria, the value would be -1 - 0 = "-1".
I want to know the simplest code. I have been creating a variable that is the last value, and another variable that's the first value, and blah blah but i need to do this for so many variables, so i would that'd be a one liner command or something?
thank you!
Related Posts with creating a variable that takes a value of the difference of the last non-missing value and the first non-missing value in panel data
Conflicting results in did and dose response modelsDear All, I am looking to the impact of Syrian mass migration on the firm-level performance measure…
Code blocks on this forum need fixingThe code blocks on this forum give weird output every now and then. Specifically, multi-line code is…
Generate/replace new variables in a repetitive way for all the individuals.Hello, everyone. Below is my data and variable name "salary21" means salary of PID 21, and each val…
Change over timeHi all, I have a data-set of organizations and their service sites for 2014-2018. Organizations 1) o…
Small sample of 38 observationsHi, I have a panel data of 26 countries and 21 years, but I am only concerned with 38 observations.…
Subscribe to:
Post Comments (Atom)
0 Response to creating a variable that takes a value of the difference of the last non-missing value and the first non-missing value in panel data
Post a Comment