cryptodatapy 0.2.28__tar.gz → 0.2.29__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/PKG-INFO +1 -1
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/pyproject.toml +1 -1
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/conf/tickers.csv +1 -1
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/cryptocompare_api.py +2 -1
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/util/utils.py +10 -7
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/LICENSE +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/README.md +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/conf/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/conf/fields.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/br_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/ca_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/cn_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/de_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/ez_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/fr_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/gb_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/get_econ_calendars.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/id_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/in_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/it_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/jp_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/kr_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/mx_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/ru_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/tr_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/datasets/us_econ_calendar.csv +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/.ipynb_checkpoints/CCXT-checkpoint.ipynb +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/.ipynb_checkpoints/DBNomics-checkpoint.ipynb +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/.ipynb_checkpoints/InvestPy-checkpoint.ipynb +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/.ipynb_checkpoints/NasdaqDataLink-checkpoint.ipynb +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/.ipynb_checkpoints/PandasDataReader-checkpoint.ipynb +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/coinmetrics_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/datavendor.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/glassnode_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/polygon_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/tiingo_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/datarequest.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/exchanges/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/exchanges/dydx.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/exchanges/exchange.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/getdata.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/ccxt_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/dbnomics_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/investpy_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/library.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/pandasdr_api.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/web/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/web/aqr.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/web/web.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/clean.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/convertparams.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/filter.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/impute.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/od.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/transform/wrangle.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/util/__init__.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/util/datacatalog.py +0 -0
- {cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/util/datacredentials.py +0 -0
@@ -1796,7 +1796,7 @@ GB_M0,"UK M0 Money Supply, NSA","Monthly average amount outstanding of total ste
|
|
1796
1796
|
GB_M1,"UK M1 Money Supply, NSA","Monthly average amount outstanding of total sterling notes and coin in circulation, excluding backing assets for commercial banknote issue in Scotland and Northern Ireland (in sterling millions) seasonally adjusted",,GB,GBR,United Kingdom,DM,macro,money,,m,,GBP ,GBP ,,,,,MANMM101GBM189N,,,,
|
1797
1797
|
US_M2,"United States M2, Money Supply, SA",,,US,USA,United States,DM,macro,money,,m,,billion usd,USD,,,,,M2SL,FED/H6_H6_M2/M2.M,,,
|
1798
1798
|
CN_M2,"China M2, Money Supply, NSA",,,CN,CHN,China,EM,macro,money,,m,,100 million yuan,CNY,,,,,MYAGM2CNM189N,NBS/M_A0D01/A0D0101,M2 Money Stock (YoY),,
|
1799
|
-
EZ_M2,"Eurozone M2, Money Supply, SA",,,EZ,EMU,Euro zone,Euro zone,macro,money,,m,,million euro,EUR,,,,,
|
1799
|
+
EZ_M2,"Eurozone M2, Money Supply, SA",,,EZ,EMU,Euro zone,Euro zone,macro,money,,m,,million euro,EUR,,,,,MYAGM2EZM196N,ECB/BSI/M.U2.N.V.M20.X.1.U2.2300.Z01.E,,,
|
1800
1800
|
JP_M2,"Japan M2, Total, SA",,,JP,JPN,Japan,DM,macro,money,,m,,JPY ,JPY ,,,,,MYAGM2JPM189S,ECB/RTD/M.JP.Y.M_M2.J,,,
|
1801
1801
|
GB_M3,"UK M3, Total, SA",,,GB,GBR,United Kingdom,DM,macro,money,,m,,GBP ,GBP ,,,,,MABMM301GBM189S,BOE/7989/LPMVWXL,,,
|
1802
1802
|
GB_M4,"UK M4, Total, SA",,,GB,GBR,United Kingdom,DM,macro,money,,m,,GBP ,GBP ,,,,,,BOE/36785/LPMAUYN,,,
|
@@ -711,7 +711,8 @@ class CryptoCompare(DataVendor):
|
|
711
711
|
# tickers list
|
712
712
|
self.get_assets_info(as_list=True)
|
713
713
|
self.get_indexes_info(as_list=True)
|
714
|
-
|
714
|
+
oc_tickers = self.get_onchain_tickers_info(as_list=True)
|
715
|
+
tickers_list = self.assets + self.indexes + oc_tickers
|
715
716
|
|
716
717
|
# fields
|
717
718
|
self.get_fields_info()
|
@@ -7,14 +7,14 @@ def compute_reference_price(dfs: List[pd.DataFrame],
|
|
7
7
|
trim_pct: float = 0.25,
|
8
8
|
) -> pd.DataFrame:
|
9
9
|
"""
|
10
|
-
Computes the
|
10
|
+
Computes the reference price from a list of dataframes.
|
11
11
|
|
12
12
|
Parameters
|
13
13
|
----------
|
14
14
|
dfs: pd.DataFrame
|
15
15
|
List of dataframes containing price data.
|
16
16
|
method: str, optional
|
17
|
-
Method to compute the
|
17
|
+
Method to compute the reference price. Options are 'median' or 'trimmed_mean'.
|
18
18
|
Default is 'median'.
|
19
19
|
trim_pct: float, optional
|
20
20
|
Percentage of data to trim from both ends for 'trimmed_mean' method.
|
@@ -22,7 +22,7 @@ def compute_reference_price(dfs: List[pd.DataFrame],
|
|
22
22
|
Returns
|
23
23
|
-------
|
24
24
|
pd.DataFrame
|
25
|
-
Dataframe with the
|
25
|
+
Dataframe with the reference price.
|
26
26
|
"""
|
27
27
|
if not List:
|
28
28
|
raise ValueError("The input list is empty.")
|
@@ -30,9 +30,9 @@ def compute_reference_price(dfs: List[pd.DataFrame],
|
|
30
30
|
# Concatenate all dataframes in the list
|
31
31
|
stacked_df = pd.concat(dfs)
|
32
32
|
|
33
|
-
# Compute
|
33
|
+
# Compute ref price based on the specified method
|
34
34
|
if method == 'median':
|
35
|
-
|
35
|
+
ref_price = stacked_df.groupby(['date', 'ticker']).median()
|
36
36
|
|
37
37
|
elif method == 'trimmed_mean':
|
38
38
|
# Calculate trimmed mean with specified bounds
|
@@ -43,11 +43,11 @@ def compute_reference_price(dfs: List[pd.DataFrame],
|
|
43
43
|
filtered_df = stacked_df[(stacked_df >= lower_bound.reindex(stacked_df.index)) &
|
44
44
|
(stacked_df <= upper_bound.reindex(stacked_df.index))]
|
45
45
|
|
46
|
-
|
46
|
+
ref_price = filtered_df.groupby(level=[0, 1]).mean()
|
47
47
|
else:
|
48
48
|
raise ValueError("Method must be either 'median' or 'trimmed_mean'.")
|
49
49
|
|
50
|
-
return
|
50
|
+
return ref_price.sort_index()
|
51
51
|
|
52
52
|
|
53
53
|
def stitch_dataframes(df1: pd.DataFrame, df2: pd.DataFrame) -> pd.DataFrame:
|
@@ -70,6 +70,9 @@ def stitch_dataframes(df1: pd.DataFrame, df2: pd.DataFrame) -> pd.DataFrame:
|
|
70
70
|
updated_df = df1.reindex(index=df2.index, columns=df2.columns).fillna(df2)
|
71
71
|
combined_df = df1.combine_first(updated_df)
|
72
72
|
|
73
|
+
# Convert to float64 to ensure consistent data type
|
74
|
+
combined_df = combined_df.convert_dtypes().astype('float64')
|
75
|
+
|
73
76
|
return combined_df
|
74
77
|
|
75
78
|
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/__init__.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/coinmetrics_api.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/datavendor.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/glassnode_api.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/polygon_api.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/data_vendors/tiingo_api.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/dbnomics_api.py
RENAMED
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/investpy_api.py
RENAMED
File without changes
|
File without changes
|
{cryptodatapy-0.2.28 → cryptodatapy-0.2.29}/src/cryptodatapy/extract/libraries/pandasdr_api.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|