Skip to main content

sectors

ETF Sector weighting.

Example​

from openbb import obb
obb.etf.sectors("SPY", provider="fmp")

Parameters​

NameTypeDescriptionDefaultOptional
symbolstrSymbol to get data for. (ETF)False
providerLiteral['fmp', 'tmx']The provider to use for the query, by default None. If None, the provider specified in defaults is selected or 'fmp' if there is no default.fmpTrue

Returns​

OBBject
results : List[EtfSectors]
Serializable results.

provider : Optional[Literal['fmp', 'tmx']]
Provider name.

warnings : Optional[List[Warning_]]
List of warnings.

chart : Optional[Chart]
Chart object.

extra : Dict[str, Any]
Extra info.

Data​

NameTypeDescription
sectorstrSector of exposure.
weightfloatExposure of the ETF to the sector in normalized percentage points.