Data Table Unstacked (Wide) vs Stacked (Long) Format

In R, the nomenclature is called either 'wide' or 'long' format.

  • See 'reshape' utility (or reshape package).

  • See 'melt'.

  • See 'plyr'.

In Statistica, the equivalent is "stacking" or "unstacking" under the Data menu.

The WIDE format is one that is often used in MS Excel as data is collected from an experiment.

For analysis, the WIDE format is useful for Repeated Measures (including the dependent variables t-test), MANOVA, and similar methods. When using Statistica, it can also be used for an independent variables t-test "by variables".

The LONG format is the more common format for ANOVA, DOE, Regression, and similar methods.

When transferring MS Excel data in the WIDE format to the LONG format, the column headers in the WIDE format become a grouping variable in the LONG format.