• Community
    • Home
    • Welcome
      • Getting Started
      • Community Memo
      • All Things Community
      • SAS Customer Recognition Awards (2024)
      • SAS Customer Recognition Awards (2023)
    • SAS Community Library
    • SAS Product Suggestions
    • Upcoming Events
    • SAS Customer Recognition Awards
    • All Recent Topics
  • Learn
    • New SAS User
    • SAS Software for Learning Community
    • Ask the Expert
    • SAS Certification
    • SAS Tips from the Community
    • SAS Training
      • Programming 1 and 2
      • Advanced Programming
      • Course Case Studies and Challenges
      • Trustworthy AI
    • SAS Global Forum Proceedings 2021
    • Tech Report Archive
    • SAS Insights Archive
  • Programming
    • SAS Programming
    • SAS Procedures
    • SAS Enterprise Guide
    • SAS Studio
    • Graphics Programming
    • ODS and Base Reporting
    • SAS Code Examples
    • SAS Web Report Studio
    • Developers
  • Analytics
    • Statistical Procedures
    • SAS Data Science
    • Mathematical Optimization, Discrete-Event Simulation, and OR
    • SAS/IML Software and Matrix Computations
    • SAS Forecasting and Econometrics
    • Streaming Analytics
    • Research and Science from SAS
  • SAS Viya
    • SAS Viya
    • SAS Viya on Microsoft Azure
    • SAS Viya Release Updates
    • Moving to SAS Viya
    • SAS Visual Analytics
    • SAS Visual Analytics Gallery
    • Your Journey to Success
    • SAS Viya Workbench
      • SAS Viya Workbench: Getting Started
      • SAS Viya Workbench Discussion
      • SAS Viya Workbench: Release Updates
  • Administration
    • Administration and Deployment
    • Architecture
    • SAS Hot Fix Announcements
    • SUGA
  • Solutions
    • Microsoft Integration with SAS
    • Decisioning
    • SAS Decision Builder
    • Data Management
    • Customer Intelligence
      • SAS Customer Intelligence
      • SAS Customer Intelligence 360 Release Notes
      • SAS 360 Match
    • Risk and Fraud
      • SAS Risk Management
      • Fraud, AML and Security Intelligence
      • SAS Risk Release Updates
      • Risk & Finance Analytics
      • Insurance Fraud
      • MRM AI Governance Working Group
      • SAS Quant Community
    • SAS Health
      • SAS Health and Life Sciences
      • SAS Life Science Analytics Framework
  • Hubs
    • Regional Hubs
      • SAS User Groups
      • SAS Community Nordic
      • AML Nordic User Group
      • SAS Japan
      • SAS Korea
      • CoDe SAS German
      • SAS Plattform Netzwerk
      • SAS Brazil Community
      • SAS Spanish Community
      • SAS Users Group in Israel
      • 欢迎来到SAS中文社区!
      • Ottawa Area SAS Users' Society
      • Toronto Area SAS Users Group
      • SAS Türkiye Community
    • Special Interest Hubs
      • SAS Hacker's Hub
      • SAS Innovate 2025
      • SAS Analytics Explorers
      • The Curiosity Cup
      • SAS Inner Circle Panel
      • SAS Hackathon Team Profiles (Past)
      • SAS Explore
      • Reporting and Optimization
      • Intern Alumni Network Community
Sign In

Search the Community

Showing results for 
Search instead for 
Did you mean: 
Search Options
  • Subscribe to RSS Feed for this Search
Advanced Hide Advanced
  • Posts
  • Users
  • Places
  • Products
Advanced Search Options
Search Modifiers:
You can apply modifiers to the terms you enter in the search field.
Use quotes to search for an "exact phrase".
Use the plus sign to search for +one +or +more +words.
Use the minus sign to -exclude -certain -words from your search.
Limits search results to topics that have no replies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
413 results
Sorted by:
Best Match
  • Date
  • Views
  • Likes
  • Replies
  • Best Match

data reshaping

by Calcite | Level 5 nbora in New SAS User
‎12-12-2024 03:27 PM
‎12-12-2024 03:27 PM
...0DEC2013 456 987654321DEF 31JAN2014 456 987654321GHI 02FEB2014 ;​ I would like to reshape this data where the values of col_b are transposed to new columns and the minimum of the date column per c...

Reshaping data

by Calcite | Level 5 coder1 in SAS/IML Software and Matrix Computations
‎05-23-2018 04:23 PM
‎05-23-2018 04:23 PM
I want to reshape a matrix created in IML and convert it to a sas dataset while retaining the column and row names. For example,  suppose I have an N by N matrix with row and column names.&n...
Show results in replies (1)
  • ...y writing the rownames directly instead of writing two data sets and merging the data: &n...

Reshaping data

by Barite | Level 11 Miracle in SAS Data Management
‎08-27-2015 10:03 PM
‎08-27-2015 10:03 PM
Dear SAS community, wish you all well. Can I please ask how do I improve my SAS code to my problem? I have included a small partial output of how my exact data is like. I wish to reshape my data...
Show results in replies (1)
  • data want (keep=site role gender freq); set have; retain site 0; array f {*} f2-f7; do role = 1...

Reshaping data from long to wide

by Fluorite | Level 6 jlee8 in SAS Programming
‎11-04-2020 05:35 PM
‎11-04-2020 05:35 PM
Hello,   I'm not sure if SAS does support a manipulation like this but if there is a way, please advise.   I have a dataset that look like the following.    From &n...
Show results in replies (1)
  • ...tutorials: Long to Wide: https://stats.idre.ucla.edu/sas/modules/how-to-reshape-data-long-to-w...

Reshaping the Data

by Obsidian | Level 7 kngu022 in New SAS User
‎02-15-2020 08:47 AM
‎02-15-2020 08:47 AM
I have this codes below. As I understand the length of item is from 1-13, IDnum is from 15-19 , Instock 21-22  backord 24-25. the order that variable will be stored in the data is item i...
Show results in replies (1)
  • Hi @kngu022,   During the compilation phase (before execution), the Program Data V...

How to reshape data?

by Obsidian | Level 7 ervinodsingh in SAS Programming
‎05-09-2017 07:31 AM
‎05-09-2017 07:31 AM
Hi have data like  a 4 a 3 a 6 b 3 b 7 b 8 c 1 c 5 c 7   and want my data to the form  4 3 1 3 7 5 6 8 7    
Show results in replies (1)
  • Or the followng code could get you more slick. No need input 3 by hand .   data have; i...

How to reshape data?

by Pyrite | Level 9 GPatel in SAS Programming
‎05-26-2016 06:09 PM
‎05-26-2016 06:09 PM
  RAW_DATA               Obs Flag_A Flag_B Flag_C Flag_D Flag_E Flag_F Flag_G N 1 No       ...
Show results in replies (1)
  • Arrays would come in handy, especially if you actually have more than six variables:   data...

Reshape data to conduct Descriptive Analysis

by Fluorite | Level 6 Sofianeuk in SAS Programming
‎06-14-2019 05:19 AM
‎06-14-2019 05:19 AM
Hello,   i have a sales dataset as shown below, i am facing a problem to manipulate the data with the Dates presented as attributes in the top row, can someone suggest a method to reshape t...
Show results in replies (3)
  • ...nd memname = 'HAVE' and name EQT '_'; quit; %put &=monthlist; * Reshape data - transform to M...
  • ...uggest a method to reshape the data to be able to use the dataset in my descriptive analysis , &n...
  • ...5 2013, 06 2013, 07 3013 etc..) as attributes wont help me much, i think ill need to reshape the d...

Data Transformation: Reshape Wide to Long

by Obsidian | Level 7 renanm in SAS Programming
‎06-20-2019 09:11 AM
‎06-20-2019 09:11 AM
...o looking for some help/guidance.   I have a dataset that looks like: data have; input id tr1 tr2 tr3 tr4; cards; 1 AAA BBB GGG FFF 2 DDD CCC AAA BBB 3 BBB AAA JJJ VVV ; run;   The o...
Show results in replies (1)
  • Examine your data. I will bet that you find that you have duplicate values of one or more values o...

Reshape long data into wide data

by Obsidian | Level 7 Angi in SAS Procedures
‎01-26-2015 05:52 AM
‎01-26-2015 05:52 AM
...student can have different types of violations that fall under the same incident type; and c) different students have different number of incidents and violations. How do I reshape this long data...
Show results in replies (1)
  • Sorry. My bad. Try this one : data have; input id incident_date : date11. i...
  • « Previous
    • 1
    • 2
    • 3
  • Next »
Powered by Khoros