predicting-stock-market-crashes's People
Forkers
maxprog profshen jmsung xr97 vijaykumarsh bhoang alexbelarus libardo1 lppier andrewczgithub deng1689 bthecorgi stonemeisterw sfireworks battyone satishadhikari gmineo droiter leanderdulac thales-sakamoto zhgu-dev hermian chiu-huang faisalnawazmir chendongyu0125 wealthcreating chintan1083 mvgjorge popquants lauraalvesp drizham rayiys shashwat5a nanditamishra upproved shryesth wi11iamj djangu-algo hkdavid2008 kabbathi purumi77 moneymatrixbot hechoi37predicting-stock-market-crashes's Issues
Wrong drawdown calculation?
I don't think the drawdowns are computed correctly. By definition drawdowns are computed as follows:
Drawdowns from returns dfr
as a dataframe:
# compute the wealth index from the non-cumulative returns
dfw = (1+dfr).cumprod()
# compute the drawdowns
dd = dfw / dfw.cummax() - 1
Drawdowns from prices dfp
as a dataframe:
# compute the wealth index from prices
dfw = dfp / dfp.iloc[0, :]
# compute the drawdowns
dd = dfw / dfw.cummax() - 1
A simple check of your drawdowns being incorrect: compare to the underwater plot. You will see that the drawdowns you compute don't go from peak to trough. If this is incorrect all the downstream work will need to be revisited.
I believe the problem lies in the following computation. Here you get a marking on any decreasing price sequence but these are not the drawdowns. The drawdowns require the cumulative price maximum.
pmin_pmax = (ds['price'].diff(-1) > 0).astype(int).diff() #<- -1 indicates pmin, +1 indicates pmax
ModuleNotFoundError
Hi ,
I have already installed pip install scikit-learn but its not help to resolve error. Please help on following error
C:\Python39\Predicting-Stock-Market-Crashes-master\Predicting-Stock-Market-Crashes-master\final_predictor\main.py
Traceback (most recent call last):
File "C:\Python39\Predicting-Stock-Market-Crashes-master\Predicting-Stock-Market-Crashes-master\final_predictor\main.py", line 94, in
main()
File "C:\Python39\Predicting-Stock-Market-Crashes-master\Predicting-Stock-Market-Crashes-master\final_predictor\main.py", line 44, in main
model = pickle.load(open(model, 'rb'))
ModuleNotFoundError: No module named 'sklearn.linear_model.logistic'
Download new data and change the target variable.
Hi @roman807 ,
I want to try and recreate the project with the latest data and add some more
analytics.
I was wondering if you had the script to download the csv data sets.
Also I want to change to the target variable to a draw down in the 5% percent region.
I was wondering where in the code I could do this and re-run the experiments.
Many thanks,
Best,
Andrew
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.