In my regressions, I add variables across five specifications in which the last contains all the variables in my model. As each specification is based on different samples, I cannot accurately compare results between them. I understand one way of addressing this is to 'fix' the sample to the observations in the final (5th) specification as it contains all the variables added across the previous specifications. Doing so, I understand, will ensure the samples in each are the same, therefore, allowing more accurate comparisons of results across specifications.

To do this, I thought of generating a new variable, which equals the variables in the final specification and adding this new variable to each of the first four specifications to ensure the samples are the same. I'm not sure, but would it look something like:
Code:
generate fixed2 = faith2 + at3 + attend_diff + hgage1 + hgage2 + agediff + esbrd1 + esbrd2 + child + linc
then adding
Code:
if fixed2 == 1
to the first four specifications. (I've not addressed missing values yet). Some guidance on approach/code is appreciated.

Here's an example of my data:
Code:
input byte(faith2 at3) float attend_diff int(hgage1 hgage2) byte(agediff esbrd1 esbrd2) float child byte linc
 2 0 0 49 48  1 3 1 2 10
 2 0 0 50 49  1 1 1 2  9
 2 0 0 51 50  1 1 1 2 10
 2 0 0 52 51  1 1 1 2 10
 6 0 0 48 38 10 1 1 3  9
 6 0 0 49 39 10 1 1 3  9
 6 0 0 50 40 10 1 1 3  9
 6 0 0 51 41 10 1 1 3  8
 1 0 0 20 22  2 2 3 .  9
 1 0 0 30 23  7 . 1 . 11
 1 0 0 31 24  7 1 1 . 11
 1 0 0 32 25  7 1 3 . 11
 1 0 0 33 26  7 1 1 . 11
 1 0 0 34 27  7 1 1 . 10
 1 0 0 35 28  7 1 1 .  .
 1 0 0 36 29  7 1 1 . 11
 1 0 0 37 30  7 1 3 . 11
 1 0 0 38 31  7 1 2 . 11
 1 0 0 39 32  7 1 3 . 11
 3 0 0 47 44  3 1 1 . 11
 3 0 0 48 45  3 1 1 . 11
 3 0 0 49 46  3 1 1 . 11
 3 0 0 50 47  3 1 1 . 11
 3 0 0 51 48  3 1 1 . 11
 3 0 0 52 49  3 1 1 . 11
 3 0 0 53 50  3 1 1 . 11
 3 0 0 54 51  3 1 1 . 11
end
I'm using panel data.
Stata v.15.1.