将矩阵转换为3列表('reverse pivot','unpivot','flatten','normalize') [英] Convert matrix to 3-column table ('reverse pivot', 'unpivot', 'flatten', 'normalize')

查看:160
本文介绍了将矩阵转换为3列表('reverse pivot','unpivot','flatten','normalize')的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要转换表 LATER 中的Excel矩阵 FIRST

I need to convert the Excel matrix FIRST in the table LATER:

FIRST

    P1  P2  P3  P4
F1  X
F2  X   X
F3      X       X
F4      X   X

LATER

F   P   VALUE
F1  P1  X
F1  P2
F1  P3
F1  P4
F2  P1  X
F2  P2  X
F2  P3
F2  P4
F3  P1
F3  P2  X
F3  P3
F3  P4  X
F4  P1
F4  P2  X
F4  P3  X
F4  P4


推荐答案

要反转枢轴,不透明或展平:



To "reverse pivot", "unpivot" or "flatten":


  1. 对于Excel 2003:激活摘要表中的任何单元格,然后选择数据 - 数据透视表和数据透视图报表:

  1. For Excel 2003: Activate any cell in your summary table and choose Data - PivotTable and PivotChart Report:

对于l ater版本使用 Alt + D P 访问向导。

For later versions access the Wizard with Alt+D, P.

对于Excel for Mac 2011,它是 + Alt + P (< a href =https://support.office.com/en-us/article/Consolidate-multiple-data-sources-in-a-PivotTable-8f476919-40b3-4133-9870-26f4d9f21ad6>参见这里)。

For Excel for Mac 2011, it's +Alt+P (See here).


  1. 选择多个合并范围,然后点击下一步

  1. Select Multiple consolidation ranges and click Next.

在步骤2a的3中,选择我将创建页面字段,然后单击下一步

In "Step 2a of 3", choose I will create the page fields and click Next.

在步骤2b of 3中,在范围字段中指定汇总表范围(A1:E5为示例数据),然后单击添加,然后下一页

In "Step 2b of 3" specify your summary table range in the Range field (A1:E5 for the sample data) and click Add, then Next.

在第3步,共3步中,选择枢纽表的一个位置PT只需临时使用):

In "Step 3 of 3", select a location for the pivot table (the existing sheet should serve, as the PT is only required temporarily):

点击完成创建数据透视表:

向下钻取即双击)在Grand Totals(这里是Cell V7或 7 )的相交处:

Drill down (ie double-click) on the intersect of the Grand Totals (here Cell V7 or 7):

现在可以删除PT。






启动Excel ,我认为优质。

这篇关于将矩阵转换为3列表('reverse pivot','unpivot','flatten','normalize')的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆