-
-
Notifications
You must be signed in to change notification settings - Fork 422
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Chapter 7, Do the portfolio's which have negative weights for stocks like weights[1] mean to sell those? #5
Comments
Also when looking at the returns for on the actual chart the graph goes all the way up to 8+ on the y axis, therefore I am confused how this 8 aligns with the 99% return, is this a 99% return year over year resulting in 8x return? or how do i define this clearer? |
Also a question about the linear regression stock predictions, is there a way to convert the returns into the actual predicted number/price for the specific time period, from what im thinking one could multiply the starting price by each row im just unsure how to write the code to do this, im just thinking in order to fit the problem to smaller time scales, but i guess i could just use a calculator manually but would be cool to automate the process |
does this mean to short the negatives or not include them completely in the portfolio? also could i please reference your book in my book, I have been granted permission from Dr Yves Hilspisch to use a couple quotes from his books in mine, would you mind if i did the same with yours, as I feel this book was of a high standard versus what is currently on the market and i would like to pull a few quotes from your introductory section if possible, while also pointing readers to your book for further reference would that be okay? |
eigen_prti_returns = np.dot(X_train_raw.loc[:, eigen_prtfi.index], pc_w) after sorting the indices in eigen_prtfi.index (in the previous step), the stocks in X_train_raw.loc[:, eigen_prtfi.index] don't match with the weights in pc_w. Don't understand this. This way the results depend on how the stocks are arranged in the dataset. |
Hi i just wanted to clarify if for example portfolio 2 / weights[2] which has negative weights does that mean in the portfolio its meant to be a sell with such a weight?
example : weights
WMT 154.600
HD 98.409
WBA 83.098
INTC 73.599
MRK 70.360
PG 69.292
VZ 67.323
KO 63.387
CSCO 59.287
PFE 57.201
MSFT 54.698
JNJ 50.306
MCD 50.279
IBM 39.230
NKE 32.219
AAPL 26.293
DIS 26.185
AXP -3.605
TRV -16.914
UNH -32.764
JPM -35.070
GS -53.526
MMM -64.635
BA -78.023
UTX -83.237
CAT -133.755
XOM -225.916
CVX -248.319
or do the negative numbers just mean do nothing with them?
The text was updated successfully, but these errors were encountered: