fix
This commit is contained in:
2
setup.py
2
setup.py
@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name='ttools',
|
name='ttools',
|
||||||
version='0.2.5',
|
version='0.2.6',
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
install_requires=[
|
install_requires=[
|
||||||
'vectorbtpro',
|
'vectorbtpro',
|
||||||
|
|||||||
@ -81,7 +81,7 @@ def register_custom_inds(indicator_name: str = None, if_exists: str ="skip"):
|
|||||||
else:
|
else:
|
||||||
for var_name, var_value in globals().items():
|
for var_name, var_value in globals().items():
|
||||||
if var_name.startswith("IND_") and isinstance(var_value, vbt.IndicatorFactory):
|
if var_name.startswith("IND_") and isinstance(var_value, vbt.IndicatorFactory):
|
||||||
vbt.IF.deregister_custom_indicator(var_value, location="ttools")
|
vbt.IF.register_custom_indicator(var_value, location="ttools", if_exists=if_exists)
|
||||||
|
|
||||||
def deregister_custom_inds(indicator_name: str = None):
|
def deregister_custom_inds(indicator_name: str = None):
|
||||||
"""Deregister a custom indicator or all custom indicators.
|
"""Deregister a custom indicator or all custom indicators.
|
||||||
@ -101,4 +101,4 @@ def deregister_custom_inds(indicator_name: str = None):
|
|||||||
else:
|
else:
|
||||||
for var_name, var_value in globals().items():
|
for var_name, var_value in globals().items():
|
||||||
if var_name.startswith("IND_") and isinstance(var_value, vbt.IndicatorFactory):
|
if var_name.startswith("IND_") and isinstance(var_value, vbt.IndicatorFactory):
|
||||||
vbt.IF.rdeegister_custom_indicator(var_value, location="ttools")
|
vbt.IF.deregister_custom_indicator(var_value, location="ttools")
|
||||||
Reference in New Issue
Block a user