tr8dr / tseries-patterns

trend / momentum and other patterns in financial timeseries
MIT License
237 stars 71 forks source link

Package Windows Env #3

Open LinuxpowerLudo opened 4 years ago

LinuxpowerLudo commented 4 years ago

Hello,

You have test your package on Windows environnement ?

And another question : how access to BSI values directly with a print by example ?

Thx. Regards.

tr8dr commented 4 years ago

As for accessing BSI values added a return to the eval method, which will return a dataframe containing bars and BSI value:

metrics = obj.eval (df)
metrics.bsi

I have not tested the package on windows (I use OSX and Linux, but do not have access to windows). You would need a C++ compiler on windows (could probably install the GNU compiler). Alternatively could create pure python implementation, but would be slow.

I came across this link related to setting up the project to be built on windows, but do not have a way to test:

https://zhuanlan.zhihu.com/p/32814456

LinuxpowerLudo commented 4 years ago

Thank you for your code modifications.

First i test your example on my box linux but i have a trouble for print bsi values..

df = pd.read_csv("csv/volumebars.csv", parse_dates=['stamp']) obj = HawkesBSI(0.1) metrics=obj.eval(df) print(metrics.bsi)

and i have :

Traceback (most recent call last): File "bsi.py", line 9, in print(metrics.bsi) AttributeError: 'NoneType' object has no attribute 'bsi'

metrics return None.. :(

tr8dr commented 4 years ago

I added the return in eval just this morning, so you would need to pull / reinstall the package. I will check your example later today when I have a little time.

tr8dr commented 4 years ago

I just checked the above code you provided. With the modification I made this morning, metrics does indeed contain the result data frame and not None. Hope that solves the problem for you.

LinuxpowerLudo commented 4 years ago

Yes thanks you Jonathan !

with a uninstall and install sound good ! :)

LinuxpowerLudo commented 4 years ago

Hi Jonathan,

Can you do the same modification for the HawkesBVC when you had a little time ? :)

Many thanks. Regards

tr8dr commented 4 years ago

added, you can reinstall again.