diff --git a/precog/utils/cm_data.py b/precog/utils/cm_data.py index 5d4b086..f1545a5 100644 --- a/precog/utils/cm_data.py +++ b/precog/utils/cm_data.py @@ -28,11 +28,22 @@ def get_CM_ReferenceRate( parallelize: bool = False, time_inc_parallel: pd.Timedelta = pd.Timedelta("1h"), **kwargs, - ) -> pd.DataFrame: + ) -> pd.DataFrame: """Fetches CM Reference Rate for specific asset ticker or list of tickers from CoinMetrics Python client. + Args: + assets (Union[list, str]): Asset ticker or list of tickers to retrieve CM Reference Rates for + start (Optional[Union[datetime, date, str]], optional): Start time of data, if None will return earliest available. Defaults to None. + end (Optional[Union[datetime, date, str]], optional): End time of data, if None will return earliest available. Defaults to None. + end_inclusive (bool, optional): Whether to include a data point occuring at the "end" time. Defaults to True. + frequency (str, optional): Frequency of prices - '200ms', '1s', '1m', '1m', '1d'. Defaults to "1s". + page_size (int, optional): Page size of return, recommended 10000. Defaults to 10000. + parallelize (bool, optional): Whether to parallelize query into multiple queries. + Can speed up retrieval but may go over usage limits. Defaults to False. + time_inc_parallel (pd.Timedelta, optional): If using parallelize, time interval queried by each thread. Defaults to pd.Timedelta("1h"). + Returns: - DataFrame: Reference Rate of assets over time, with columns + pd.DataFrame: Reference Rate of assets over time, with columns ['asset', 'time', 'ReferenceRateUSD'] Notes: