revenue
- Model
- Chart
Governments collect revenues mainly for two purposes: to finance the goods
Source Code: [link]
openbb.economy.revenue(countries: Optional[List[str]], units: str = "PC_GDP", start_date: Any = "", end_date: Any = "")
Parameters
Name | Type | Description | Default | Optional |
---|---|---|---|---|
countries | list | List of countries to get data for | None | False |
units | str | Units to get data in. Either 'PC_GDP' or 'THOUSAND_USD_PER_CAPITA'. Default is Percentage of GDP. | PC_GDP | True |
start_date | str | Start date of data, in YYYY-MM-DD format | True | |
end_date | str | End date of data, in YYYY-MM-DD format | True |
Returns
Type | Description |
---|---|
pd.DataFrame | Dataframe with revenue data |
Governments collect revenues mainly for two purposes: to finance the goods
Source Code: [link]
openbb.economy.revenue_chart(countries: Optional[List[str]], units: str = "PC_GDP", start_date: str = "", end_date: str = "", raw: bool = False, export: str = "", sheet_name: str = "", external_axes: bool = False)
Parameters
Name | Type | Description | Default | Optional |
---|---|---|---|---|
countries | list | List of countries to get data for | None | False |
units | str | Units to get data in. Either 'PC_GDP' or 'THND_USD_CAP'. Default is Percentage of GDP. | PC_GDP | True |
start_date | str | Start date of data, in YYYY-MM-DD format | True | |
end_date | str | End date of data, in YYYY-MM-DD format | True | |
raw | bool | Whether to display raw data in a table | False | True |
export | str | Format to export data | True | |
sheet_name | str | Optionally specify the name of the sheet the data is exported to. | True | |
external_axes | bool | Whether to return the figure object or not, by default False | False | True |
Returns
Type | Description |
---|---|
Union[OpenBBFigure, None] | OpenBBFigure object if external_axes is True, else None (opens plot in a window) |