mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-11-05 08:51:20 +00:00
Fixing Forecast SDK with data from other menus (#3554)
* minor check incase using sdk * fixes combine * datetime formating * Update forecast.md * fix testing
This commit is contained in:
22
website/content/sdk/guides/intros/forecast.md
vendored
22
website/content/sdk/guides/intros/forecast.md
vendored
@@ -64,12 +64,28 @@ help(openbb.forecast)
|
||||
|
||||
## Examples
|
||||
|
||||
### combine
|
||||
|
||||
Combine columns from different datasets
|
||||
|
||||
```python
|
||||
spy = openbb.stocks.load("spy")
|
||||
aapl = openbb.stocks.load("aapl")
|
||||
|
||||
# merge the data
|
||||
combined_df = openbb.forecast.combine(spy,aapl, dataset="aapl", column= "Close")
|
||||
openbb.forecast.show(combined_df)
|
||||
```
|
||||
<img width="507" alt="image" src="https://user-images.githubusercontent.com/105685594/203791078-181431cb-99bf-4d26-bfff-b4cf34b5dee2.png">
|
||||

|
||||
|
||||
|
||||
### corr
|
||||
|
||||
Shows a correlation matrix between columns in dataset
|
||||
|
||||
```python
|
||||
df = pd.read_csv(ANDREW_REPLACE)
|
||||
df = openbb.stocks.load("aapl")
|
||||
openbb.forecast.corr_chart(df)
|
||||
```
|
||||

|
||||
@@ -80,7 +96,7 @@ openbb.forecast.corr_chart(df)
|
||||
This command allows you to see seasonality patterns in your data
|
||||
|
||||
```python
|
||||
df = pd.read_csv(ANDREW_REPLACE)
|
||||
df = openbb.stocks.load("aapl")
|
||||
openbb.forecast.season_chart(df)
|
||||
```
|
||||
|
||||
@@ -92,7 +108,7 @@ openbb.forecast.season_chart(df)
|
||||
Predicts the future value of time series data using exponential smoothing
|
||||
|
||||
```python
|
||||
df = pd.read_csv(ANDREW_REPLACE)
|
||||
df = openbb.stocks.load("aapl")
|
||||
openbb.forecast.expo_chart(df)
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user