BookmarkSubscribeRSS Feed
cris17
Calcite | Level 5

Hi SAS communities,

 

I match merged 4 data sets into one. There should only be 1 observation per person, which includes the most recent visit. One data set had a Birth Date variable and another data set had a Visit Date variable. After merging all 4 I then had to create a new variable that shows what age the person was between Birth date and Visit Date. Below is my code and I think I did the code correctly, but in the log, it shows that 2 out of the 573 are missing data. I checked the data sets and they show both the Birth date and Visit date. It could possibly be the way I also made the 4 data sets, but want to know ifs a simple coding mistake. Below is my code and a screenshot of the partial log.

 

 

Screen Shot 2020-12-06 at 6.43.32 PM.png

 

Let me know if you need more information

Thank you.

1 REPLY 1
PaigeMiller
Diamond | Level 26

The log clearly shows that VisitDt is missing for these two observations.

 

it may be that when you merge these data sets, a missing VisitDt in one data set overwrites a non-missing VisitDt from another data set.

 

In the future, please post log as text (not screen capture) by pasting it into the window that appears when you click on the </> icon.

--
Paige Miller

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 606 views
  • 0 likes
  • 2 in conversation