bayesline.api.equity.ExposureReportAccessorImpl#

class bayesline.api.equity.ExposureReportAccessorImpl(accessor: ReportAccessorApi)#
__init__(accessor: ReportAccessorApi)#

Methods

__init__(accessor)

get([start_date, end_date])

Get the exposures for the report.

get_dates()

Get the dates for the report.

with_scenario(scenario_settings)

Return a new accessor with the given scenario settings applied.

Attributes

accessor

The underlying report accessor API.

scenario_types

__init__(accessor: ReportAccessorApi)#
property accessor: ReportAccessorApi#

The underlying report accessor API.

Returns#

ReportAccessorApi

The underlying report accessor API.

get_dates() list[date]#

Get the dates for the report.

Returns#

list[dt.date]

The dates for the report.

get(start_date: str | date | datetime | None = None, end_date: str | date | datetime | None = None) DataFrame#

Get the exposures for the report.

Parameters#

start_date: DateLike | None, default=None

The start date of the report, inclusive.

end_date: DateLike | None, default=None

The end date of the report, inclusive.

Returns#

pl.DataFrame

The exposures for the report, with a date column and all factors as columns. The factor column names are of the form factor_group^factor.