Hello, I am trying to take a table from looking like this
Name | Year |
Christina | 2011 |
Christina | 2012 |
Christina | 2013 |
Christina | 2015 |
Christina | 2020 |
Chris | 2015 |
Chris | 2016 |
Luna | 2001 |
Luna | 2023 |
Luna | 2021 |
Luna | 2013 |
Luna | 2010 |
to this
Name | Year | Start Year | Last Year |
Christina | 2011 | 2011 | 2020 |
Christina | 2012 | 2011 | 2020 |
Christina | 2013 | 2011 | 2020 |
Christina | 2015 | 2011 | 2020 |
Christina | 2020 | 2011 | 2020 |
Chris | 2015 | 2015 | 2016 |
Chris | 2016 | 2015 | 2016 |
Luna | 2001 | 2001 | 2023 |
Luna | 2023 | 2001 | 2023 |
Luna | 2021 | 2001 | 2023 |
Luna | 2013 | 2001 | 2023 |
Luna | 2010 | 2001 | 2023 |
using SAS. Any code advice is appreciated.
Any provided methods will be used on 60K+ lines of data. Not posting that information here for privacy Reasons.
Names are in Character Format and Years are in Numeric Format
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
Check out this tutorial series to learn how to build your own steps in SAS Studio.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.