corr
- Model
- Chart
Returns correlation for a given df
Source Code: [link]
openbb.forecast.corr(data: pd.DataFrame)
Parameters
| Name | Type | Description | Default | Optional |
|---|---|---|---|---|
| data | pd.DataFrame | The df to produce statistics for | None | False |
Returns
| Type | Description |
|---|---|
| pd.DataFrame | The df with the new data |
Plot correlation coefficients for dataset features
Source Code: [link]
openbb.forecast.corr_chart(dataset: pd.DataFrame, export: str = "", sheet_name: Optional[str] = None, external_axes: bool = False)
Parameters
| Name | Type | Description | Default | Optional |
|---|---|---|---|---|
| dataset | pd.DataFrame | The dataset fore calculating correlation coefficients | None | False |
| sheet_name | str | Optionally specify the name of the sheet the data is exported to. | None | True |
| export | str | Format to export image | True | |
| external_axes | bool | Whether to return the figure object or not, by default False | False | True |
Returns
This function does not return anything