qiskit.finance.data_providers.BaseDataProvider¶
-
class
BaseDataProvider
[ソース]¶ The abstract base class for data_provider modules within Qiskit’s finance module.
To create add-on data_provider module subclass the BaseDataProvider class in this module. Doing so requires that the required driver interface is implemented.
To use the subclasses, please see https://github.com/Qiskit/qiskit-tutorials/blob/master/legacy_tutorials/aqua/finance/data_providers/time_series.ipynb
Methods
__init__
()Initialize self.
Returns random coordinates for visualisation purposes.
Returns the covariance matrix.
Returns a vector containing the mean value of each asset.
Returns a vector containing the mean value of each asset.
Returns a vector containing the mean value of each asset.
Returns time-series similarity matrix computed using dynamic time warping.
run
()Loads data.
-
get_coordinates
()[ソース]¶ Returns random coordinates for visualisation purposes.
- 戻り値の型
Tuple
[float
,float
]
-
get_covariance_matrix
()[ソース]¶ Returns the covariance matrix.
- 戻り値の型
ndarray
- 戻り値
an asset-to-asset covariance matrix.
- 例外
QiskitFinanceError – no data loaded
-
get_mean_vector
()[ソース]¶ Returns a vector containing the mean value of each asset.
- 戻り値の型
ndarray
- 戻り値
a per-asset mean vector.
- 例外
QiskitFinanceError – no data loaded
-
get_period_return_covariance_matrix
()[ソース]¶ Returns a vector containing the mean value of each asset.
- 戻り値の型
ndarray
- 戻り値
a per-asset mean vector.
- 例外
QiskitFinanceError – no data loaded
-
get_period_return_mean_vector
()[ソース]¶ Returns a vector containing the mean value of each asset.
- 戻り値の型
ndarray
- 戻り値
a per-asset mean vector.
- 例外
QiskitFinanceError – no data loaded
-
get_similarity_matrix
()[ソース]¶ Returns time-series similarity matrix computed using dynamic time warping.
- 戻り値の型
ndarray
- 戻り値
an asset-to-asset similarity matrix.
- 例外
QiskitFinanceError – no data loaded
-