sas - 如何一次转置多列?
问题描述
我试图用两个变量转置三列。
我当前的数据集如下所示:
Person Date Company Industry Number
John 2017 Apple Tech 5
John 2017 Starbucks Beverages 3
Kim 2014 Hilton Hotels 9
我希望我的输出数据集看起来像:
Person | Date | Company1 | Industry1 | Number1 | Company2 |Industry2| Number2
John | 2017 | Apple | Tech | 5 | Starbucks| Beverage| 3
Kim | 2014 | Hilton | Hotels | 9 | - | - | -
如您所见,我希望每个观察的名称和日期都是唯一的。
有什么建议么?
解决方案
推荐阅读
- javascript - 如何在第一次渲染后模拟 select onchange
- amazon-web-services - 如何将docker ip地址映射到域名
- python - 如何将订购的独特物品保持在尺寸有限的结构中?
- playframework-2.0 - 如何将 play framework 1.2.4 迁移到 play 2.1?
- javascript - 如何获取 json 文件的主结构?
- ios - React Native iOS:“911”号码的telprompt在iPhone上显示为“(91)1”
- java - 切换到任何新窗口
- javascript - 收到 axios 数据后 Vue2Editor 内容未更新
- angular - 如何将数据填充到 FormGroup 中?
- apache-spark - 保留火花节点历史