Skip to main content

Posts

Showing posts from February, 2022

Visualizing Stock Price Movement With Different Returns Per Unit of Risk (Sharpe Ratio)

A stock or a investment portfolio can not be judged by just its past returns. It has to be rated with how risky it is in order to see if it's worth investing. The return per unit of risk means, how much return do I get as per how much risk I take. Also, we want to measure the return less of risk free rate, because if a risky can not generate return a return better than the risk free rate, why would I invest in it? What I am talking about is actually a famous investment term, the "Sharpe ratio", which has a formula of this: (Return - Risk Free Rate) / Portfolio Standard Deviation Sharpe Ratio Calculator By Mean and Standard deviation Risk Free Rate: % Mean Return: % Return Standard Deviation: % Submit The Sharpe Ratio is Sharpe Ratio Calculator By Entering A Series of Stock Prices, Seperated by Commas Risk Free Rate: % 10,20,30 Returns: Mean Return: % Return Standard Deviation: % S

Simulator for Comparison Withdrawing Between a SPY/Cash Portfolio And An ALL SPY One With Hypothetical Return Data

I have researched on whether we would be broke, retiring right before the 2000 and 2008 financial crises if we withdraw 4% every  year from a all IVV portfolio, the answer is that we would not. We would actually be richer after some years. Details are in this article . I also made a simulator for withdrawing 4% annually from a pure SPY portfolio, you can play with it. The simulator is here . Now, I want to find out whether a cash-SPY portfolio is better than a full SPY portfolio. Why cash? I use cash for asset allocation because cash return standard deviation is 0. meaning there do no risk. Cash has no return correction with stock. Stock price fluctuation dose not affect cash return. Therefore, cash is a good proxy for short term bond in this scenario. simulator SPY daily return mean and standard deviaion is derived from all daily closing prices from 1993/1/29 to 2022/2/5. The annual return mean is daily mean return times 252, while its standard dev

Geopolitical Events and Their Correction With Stock Market

The stock marke is experiencing some ups an downs,  not only becuse the Fed's incoming rate hikes, high PE ration of SP500 index, but also the geopolitical tension in the eastern Euriope. I put together a list of  No Date Event 1 1914/7/28 World War One 2 1939 World War Two 3 1941/12/7 Attack on Pearl Harbor 4 1950/6/25 Korean War 5 1955/11/1 Vietnam War 6 1962, October The Cuban Missile Crisis 7 2001/9/11 The 911 terrorist attacks 8 2002, October Iraq War 9 2014/2/23 Annexation of Crimea by the Russia 10 2018, January US China Tradfe War 11 2020, March Covid-19 Outbreak 12 2022, January Nort

How Much Money Do We Need to Retire?

What we need to retire is not money but rather assets. When we spend all the money, we are broke, but when we have  assets that generate monmey, we will never be broke. One of best assets for regular inestors to accumulate and reach our retirement goal is index funds. But, how much asset do we need to retire? Assume we nend $1,000 a month to cover all our living expenses, we will need 12 times $1,000 which is $12,000 per year. And with a portfolio of SPY ETF that we can safely withdeaw 4% annually from, we need $12,000/0.04 = $300,000 worth of SPY ETF.  Why 4%? I have reached this conclusion and even if we retire right at he stock market top of the 2000 or 2008 financial crises, we will still have not use up our retirement, or even, our asset value may be actually higher than before we retire. Detail calculation is in this article. I also made a simulator  to test if we would spend all our retirement selling 4% of our pure SPY portfolio.  How much money do we spend per month? He

Evaluate Mean and Standard Deviation for Asseet Allocation of SPY and Cash

Assume cash has a mean return of 0, return standard deviation of 0 and has no corration with SPY, in theroy, with x percent of cash ans 1-x percent of y, the portfolio mean return is (1-x) times SPY mean return and standard devation of (1-x) times SPY standard deviation. Mathematical proof is in this blog post. SPY has a daily mean return of 0.046% and daily return standard deviation of 1.179%. Derivation is in this blog post . Then, for example, a portfolio of 50% cash and 50% SPY will have a daily mean return of 0.046%/2= 0.023% and daily return standard deviation of 1.179%*/2 = 0.5895%. I want to test the above statistial theory by runing simulation. Simulator SPY and Cash have the above mentioned daily mean return and daily return standard deviation. This simulator will generate SPY pirces base on geometric Brownian Motion that stock prices follow. Then it calculate portfolio value and its daily rerun data. Finally, the porfolio daily returns

Bond Pricing with No Default Risks and a Fixed Interest Rate

A Bond's price is valued based on its face value, coupon rate, expiration date, term and interest rate. Calculator Assuming a bond pays semiannual coupons, its price is calculated as follows: Face value: dollar(s)  Coupon  rate:  %  Maturity:  year(s)  Yield: % How much does the above bond price change when yield change instaneously? Change in yield: % Check out the price sensitivity to yield The chart bellow shows the affect of instant change in yield to bond prices with fave value, maturity and coupon rate as your inputs above The Higher the Interest Rate, the Cheaper the Bond Price For a 10-year bond with a fave value of $100 and a coupon rate of 5% that pays coupons annually, the prices by interest rates are bellow. The Longer the Maturity, the More Sensitive the Bond Price with Interest Rate The Higher the Coupon Rate, the More Sensitive the Bond Price with Interest Rate Assume the maturity is 30 years. Bond Prices

2022 Q1 Fed Rate Hikes and Geopolitical Black Swan Events Analysis

The last high of the SP500 index was 4796.56 on the 3rd of January this year, while the lowest point so far is 4326.51 on the 27th in the same month. It took only 24 days to drop 9.8 percent. SP500 index was at the closet low of about 4300 points was on the 4th of October, which was 3 month ago. Some people blame the market downturn to the very likely rate hikes in the near future and the tension between Russia and Ukrain. Changes of Asset Prices from the Height on January 3rd to the Bottom on January 27th The SP500 has dropped 9.8%, from 4796.56 to 4326.51. Dow Jones Industrial Average has dropped 7.1%, from 36585.06 to 34160.78. Nasdaq Composite has dropped 18.6%, from 15832.80 to 13352.78. 10 Year Treasure Bond Yield has risen 1.66% from 1.637% to 1.803%,. Shares 7-10 Year Treasury Bond ETF has lost in value of  1.4% from $113.93 to $112.31. G

Economic Data Comparison and SPY Price Modeling Based on 2015 Rate hikes

The last rate hikes happened in December, 2015. The current rate hikes are about to happen. Bellow are some economic data comparison between the 2 periods. Type 2015/12 2022/2 DXY 98.24 96.03 OIL (WTI) 35.88 93.96 10 Year Rate 2.24% 1.918% Gold 1068.80 1858.68 SPY Price Simnulation Based on 2015 Decameber to 2019 July SPY Daily Return Data. I chose the SPY closing prices from 2015/12/14 to 2019/7/15 which is approximatly the period of the last rate hikes. Then I use these closing prices to calculate the mean daily return and daily return standard deviation for simulate possible future SPY price movement. Mean daily return: Daily return standard deviation: Simulate

Do 2X or 3X Bull ETFs Give 2X or 3X Returns After Certain Periods?

Do 2X or 3X Bull ETFs Give 2X or 3X Returns After Certain Periods? In order to find out I built this app. How to use this app: Specify the target return for 1X bull ETF. Specify the number of negative returns. The system will generate the positive returns. The startin price is all $100. Click the run button to see result. App Target Retrun for 1X Bull ETF: % Number of Negative Returns: times Run End of Period Return: 1X Bull: % 2X Bull: % 3X Bull: % Returns t 1x 2x 3x Conclusion After playing this app for a while, I have found that if the 1X bull return is 0% after some time, the 2X and 3X versions still have negative returns.

Simulator for Withdrawing 4% Annually from a SPY Portfolio With Hypothetical Return Data

This is a simulator for withdrawing 4% of a SPY portfolio to see if we will be broke. SPY price follows geometric Brownian motion. SPY mean daily return is 0.037% and daily return standard deviation is 1.185%, explained in this article . Assume every year has 252 trading days, we need to covert the daily return and standard deviation to the contious form so that annual return and standard deviation can be derived mathematically. Starting Portfolio Value: Annual Withdrawing Rate: % Simulate You are broke!

Mean and Standard Deviation of Time Series Data Simulator

Mathematically, a distribution has a mean of x and a standard deviation of y, the addion of 2 independent and identically random variable from that distribution will form a distribution with a mean of 2x and standard deviation of squart root of 2 times y. I built a simulator to test if the result meets the above theory. The data I use is SPY etf mean daily return and daily return standard deviaton, which is 0.046% and 1.179% respectively and I wnat to find its annual mean return and standard deviaion. In theory, they should be SPY mean annual return is 0.046% * 252 = 11.592% SPY annual return standard deviation is 1.179% * sqrt(252) = 18.716% How it works I will use SPY's daily return mean and standard deviation to create a series of daily value and record annual value every 252 days. Then calculate the mean and standard deviaiton for the annual data. Simulated SPY mean annual return is % Simulated SPY annual ret

Dollar Cost Averaging Investing Data Calculation

This tool calculates dollar cost averaging investing related data. Choose the item to be calculated:   FV      Time      RR     Sum Monthly investments:  dollar(s) Time:  year(s) Annually rate of return:  % Future value of all monthly investments:  dollar(s) Calculate . Stop The following Chart shows the power of compouding effect. Only the rate of return can not be factured out, so I used approximation which has the following JS code. //time is in month and rate is in monthly rate. function getrate(monthlyamount,futurevalue,time){ var rate = 0.01; var change = 0.01; var estimaed; var diff; do { estimaed = (monthlyamount*(Math.pow((1 + rate),time)-1)/rate); diff = estimaed-futurvalue; if(diff>0){ change /= 2; rate -= change; estimaed = ((monthlyamount*(Math.pow((1 + rate),time)-1)/rate); diff = estimaed-dendamountd; }else if(diff<0){ ratea += c