<a id="skfolio-datasets-load-sp500-index"></a>

# skfolio.datasets.load_sp500_index

<a id="skfolio.datasets.load_sp500_index"></a>

### skfolio.datasets.load_sp500_index()

Load the prices of the S&P 500 Index.

This dataset contains daily adjusted closing prices of the S&P 500 Index, covering
the period from 1990-01-02 to 2022-12-28.

#### CAUTION
This dataset is provided solely for testing and example purposes. It is a stale
dataset and does not reflect current or accurate market prices. It is not
intended for investment, trading, or commercial use and should not be relied
upon as authoritative market data.

| Observations   |   8313 |
|----------------|--------|
| Assets         |      1 |
* **Returns:**
  **df** *DataFrame of shape (n_observations, n_assets)*
  : Prices DataFrame

### Examples

```pycon
>>> from skfolio.datasets import load_sp500_index
>>> prices = load_sp500_index()
>>> prices.head()
             SP500
Date
1990-01-02  359.69
1990-01-03  358.76
1990-01-04  355.67
1990-01-05  352.20
1990-01-08  353.79
```

