📊 Dataset · CSV
aapl_tsla_merged.csv
Free CSV dataset “aapl_tsla_merged.csv” (338 rows × 7 columns, 17.9 KB) used in 3 Python lessons, including “Python Data Analytics #12: Portfolio Returns,…
- Size17.9 KB
- Rows338
- Columns7
- Used in3 lessons
Preview (first rows)
| Date | AAPL.Close | TSLA.Close | AAPL_Return | TSLA_Return | AAPL_Cumulative | TSLA_Cumulative |
|---|---|---|---|---|---|---|
| 2015-10-15 | 111.86 | 221.31 | 1.0 | 1.0 | ||
| 2015-10-16 | 111.04 | 227.01 | -0.0073 | 0.0258 | 0.9927 | 1.0258 |
| 2015-10-19 | 111.73 | 228.1 | 0.0062 | 0.0048 | 0.9988 | 1.0307 |
| 2015-10-20 | 113.77 | 213.03 | 0.0183 | -0.0661 | 1.0171 | 0.9626 |
| 2015-10-21 | 113.76 | 210.09 | -0.0001 | -0.0138 | 1.017 | 0.9493 |
| 2015-10-22 | 115.5 | 211.72 | 0.0153 | 0.0078 | 1.0325 | 0.9567 |
| 2015-10-23 | 119.08 | 209.09 | 0.031 | -0.0124 | 1.0645 | 0.9448 |
| 2015-10-26 | 115.28 | 215.26 | -0.0319 | 0.0295 | 1.0306 | 0.9727 |
Columns
| Column | Type | Missing | Example |
|---|---|---|---|
Date | text | 0 | 2015-10-15 |
AAPL.Close | decimal | 0 | 111.86 |
TSLA.Close | decimal | 0 | 221.31 |
AAPL_Return | decimal | 1 | -0.0073 |
TSLA_Return | decimal | 1 | 0.0258 |
AAPL_Cumulative | decimal | 0 | 1.0 |
TSLA_Cumulative | decimal | 0 | 1.0 |
Load it in Python
import pandas as pd
df = pd.read_csv("aapl_tsla_merged.csv")
df.head()


