Help using Base SAS procedures

How do I combine rows?

Reply
N/A
Posts: 1

How do I combine rows?

I have rows with a unique id and number of years they were active. There are in some cases two rows with the same id and I would like to combine the rows so there is only one indicator and the years combine into a sum.

PROC Star
Posts: 7,474

How do I combine rows?

You probably want to use proc summary with ID as a by variable, but you would have to provide some info about your data to get more specific guidance.  It always helps to provide a sample data file (in datastep form), along with your desired result, to get the best feedback.

Ask a Question
Discussion stats
  • 1 reply
  • 117 views
  • 0 likes
  • 2 in conversation