Help using Base SAS procedures

How to check when an observation is eliminated at which step from several tables

Reply
Occasional Contributor
Posts: 14

How to check when an observation is eliminated at which step from several tables

I am running a program where stepwise, certain criteria eliminates records from tables.  However, a record could be eliminated after the 7th table or 8th so the way I've been doing it, merging table 1 with 2, then table 2 with 3, and so on isn't very convenient.  Is there a way I can "track" an observation with flags?  Like say, if A is in table 1 then match = 1 else match = 0.  And from there, identify which table A was eliminated from (in this case Table 3).  I would need to track possibly multiple observations (not too many, maybe 5 or 10) at a time though and they may be eliminated at different points (one in Table 3, one in Table 8).

Example:

Table 1:

Pat_ID

A

B

C

D

E

F

Table 2:

A

B

D

E

F

Table 3:

B

D

E

F

Ask a Question
Discussion stats
  • 0 replies
  • 137 views
  • 0 likes
  • 1 in conversation