全部书籍

专业

应用 关于 Coach 登录 开始阅读

书籍暂未推出简体中文版——当前显示英文版。

Quantitative Finance · 术语表

什么是 Long format, wide format?

又称: long format · wide format

Definition 10.2 Research, Data and Risk Platforms · 第 10 章 — Dataframes

A table in long format has one row per observation and a column for each variable, including the keys (symbol, time, value). The same data in wide format have one row per value of one key and one column per value of another (a row per minute, a column per symbol).

The same closing prices in long format (keys as columns) and in wide format (one key as rows, the other as columns). Research code moves between the two: long for storage, joins and grouping; wide for cross-sectional arithmetic and matrices.
Figure 10.1. The same closing prices in long format (keys as columns) and in wide format (one key as rows, the other as columns). Research code moves between the two: long for storage, joins and grouping; wide for cross-sectional arithmetic and matrices.
在原文中阅读 →