bayesline.api.equity.AsyncExposureReportAccessorImpl#

class bayesline.api.equity.AsyncExposureReportAccessorImpl(accessor: AsyncReportAccessorApi)#
__init__(accessor: AsyncReportAccessorApi)#

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: AsyncReportAccessorApi)#
property accessor: AsyncReportAccessorApi#

The underlying report accessor API.

Returns#

AsyncReportAccessorApi

The underlying report accessor API.

async get_dates() list[date]#

Get the dates for the report.

Returns#

list[dt.date]

The dates for the report.

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

Get the exposures for the report.

Parameters#

start_dateDateLike | None, default=None

The start date of the report, inclusive.

end_dateDateLike | 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.