Friday, January 29, 2016

Quantopian Introduction, part 3

This is the third part of our Quantopian tutorial! Let's dive in!

Data variable and trading universe will be the topic we will start with.

A trading universe is any stock that we might be interested in trading in a given bar in our algorithm. 
The trading universe is represented by the data variable, which is a dictionary key'd by securities.

#this function is run once per bar, REQUIRED
def handle_data(context, data);
     log.info(get_datetime())
     for stock in data;

          log.info('Close price for %s: .2f' % (stock.symbol, data[stock].close_price))
     log.info('/n')

So what we did here is logged all this so we can take a look at the minute/lead/close price of each our securities ('Close price for (stock.symbol, data[stock].close_price)), and then we added in some formatting so that it all prints out in a more readable form (%s: .2f' %). And then we added the print time so we can see which minute we are on ( log.info(get_datetime()) ) And then we printed a new line for spacing ( log.info('/n') ).

Hit the 'Build Algorithm' key and what you will find is the pricing data for AAPL and SPY in each minute.

The 'stock universe' includes any stocks that we currently hold position in, as well as any stocks that we have explicitly referenced in the context variable. Another way to get a stock in our universe is to use the 'update universe function'.

Now let's turn our attention to the 'history()' function! The history function is used to us historical data for each stock in our stock universe.

#this function is run once per bar, REQUIRED
def handle_data(context, data);
    
    print history(5, '1m', 'close_price')

What this is doing is grabbing the history for our SPY and APPL data for the last 5 minute bars, and then we put '1m' for our frequency, and then we put close_price as the field that we are interested in. This returns as a pandas data frame with each column being a different stock and each row being a different date-time.

If we wanted a days frequency we would simply put '1d' instead of '1m'. Additionally, we can also change our field, so that we can find the volume traded rather than the closing price. We do this by placing 'volume' where our 'closing_price' is. 

If we want to find the ten day mean in the closing price of our stocks, we can change the number of bars to '11' and keep the frequency at '1d' and then I am actually going to save this function which, we can do through the following function: hist = history(11, '1d', 'close_price')
Now we want to make a 'for' loop going through each stock in data:

#this function is run once per bar, REQUIRED
def handle_data(context, data);
    
     hist = history(11, '1d', 'close_price')
     for stock in data:
          print '10-day mean close price for stock  %s: %2f' % (stock.symbol, np.mean(hist[stock][:-1]))

So, what we did here was print a line of text '10-day mean close price for stock' that references our stock %s: %2f' % and then we retrieve the stock symbol, and then we import the numpy library denoted as np (**NOTE: when importing a library you must also type a line of a code at the very beginning of your algorithm (above the def initialize(context) function); so above that function we would have the following line of code: import numpy as np. )
followed by the use of the statistical .mean variable of the (hist <--- our historical data for our stock. And then we type [stock] for the column that corresponds to the specific stock in our loop.
The [:-1] portion of our code excludes the last row of our column.

And the result will give us our ten day mean for AAPL and SPY.

We can change the our days to minutes like this: '10-minute mean...'

Thank you for reading part 3 of our tutorial, and as always if you have any questions or comments please send me an e-mail or comment!

Thursday, January 28, 2016

Quantopian Introduction, part 2

This is part 2 in our tutorial demonstrating how to use the online interactive investment trading tool known as Quantopian, using Python. These are the most basic code inputs that are either REQUIRED or they are OPTIONAL; the optional ones are encouraged if you have information to query before running the actual trading algorithm.

#this function is run once at the beginning of the algorithm REQUIRED
def initialize(context)
context.stock = sid(24)
     pass


#this function is run once per day before any calls to handle_data OPTIONAL
def before_trading_start(context, data)
     pass

^**This is typically where we will run calculations necessary for pre-computations that will be used for the rest of the day.


#this function is run once per bar, REQUIRED
def handle_data(context, data);
     pass

^**Ok, so this bit of code right here is retrieves data either by the minute or by the day, depending on the variable you set. Speaking of variables, the command 'handle_data' requires two inputs: context, and data.

Now let's go over securities referencing, SID, or "Security Identifier". The SID function takes care of the issues that might arise when backtesting an algorithm over an extended period of time, including if the stock ticker symbol changes. That's right, the SID function will keep the correct stock that you're using.

An example would be our previous function that we used above:
context.stock = sid(24)
..... sid(24) means that the function is calling upon the Apple stock symbol (AAPL). the (24) is the ID number given to the AAPL stock, so rather than having AAPL as the stock symbol, Quantopian identifies it by the (24) integers.

The context.stock, is a function used to store the stock data.
Next, we can 'print' out the function using the following:
     #this function is run once per bar, REQUIRED
def handle_data(context, data);
     print context.stock

Notice how this is mostly the same list of functions we used previously? The only difference is that we removed the 'pass' function and replaced it with the 'print context.stock'

A really cool feature of Quantopian with Python in this instance is that we don't have to use the ID number (SID) if we don't want to. We can simply use the following bit of code to locate the stock by it's ticker symbol:

symbol('AAPL')
**NOTE: the ticker symbol is not robust to ticker changes; in other words, if the ticker symbol changes the function will not change with it, rendering it useless. This is not a dynamic function so it is best to use the SID function instead!


Now we are going to go over how to order securities!
The portfolio value in some contexts, including this one, is calculated as the sum value of all open positions plus the cash balance.
Let's say we want half our portfolio value to be long Apple stock

     #this function is run once per bar, REQUIRED
def handle_data(context, data);
     order_target_percent(context.stock, 0.5)
This takes two parameters, the first being the stock that we want to order and the second being the target percent. The 0.5 dictates that it will take half of our available funds (0.5) and order Apple stock. So if we have $100,000 available and no open positions, this function will go through and order $50,000 of Apple stock.

Now, let's say we want to hedge our investment, we can go short in SPY, a stock that mirrors the performance of the S&P 500 index, for the other half of our portfolio.

 #this function is run once at the beginning of the algorithm REQUIRED
def initialize(context)
context.stock = sid(24)
context.market = sid(8554)
The (8554) is a reference to the SPY security.
Notice that we added the 'context.market = sid(8554)' to our previous function.

#this function is run once per bar, REQUIRED
def handle_data(context, data);
     order_target_percent(context.stock, 0.5)
     order_target_percent(context.market, -0.5)

Notice how we added 'order_target_percent(context.market, -0.5)' to our previous function? This algorithm is saying 'I want to short the SPY using half of my portfolio (-0.5). The short position is denoted by the negative ("-") symbol before the (0.5) number.

I hope you enjoyed this brief tutorial! Part 3 will be added shortly!

Let me know if you have any questions or comments!

Quantopian Introduction

Quantopian.com is pretty neat. You have access to a lot of data, can build your own algorithms, backtest them, and even have the support of the Quantopian community who will share their algorithms with you! Let's get into it here!

This introductory lesson is based upon the Quantopian tutorial, as we advance and move into more sophisticated techniques we will move away from their tutorial however I see fit. My goal is to make this simple and informative so that anyone can learn algorithmic trading without too much of a headache!

Here we go:

_________________________________________________________________________________

This is the default "Sample Mean Reversion" tutorial that I am regurgitating from Quantopian.com and in addition I will provide the reader with a deeper understanding of what's going on and why.

Background: Mean Reversion is a statistical method used in finance: Mean Reversion "is the assumption that a stocks price will tend to move to the average price over time"
"When the current market price is less than the average price, the stock is considered attractive for purchase, with the expectation that the price will rise. When the current market price is above the average price, the market price is expected to fall. In other words, deviations from the average price are expected to revert to the average"-https://en.wikipedia.org/wiki/Mean_reversion_(finance)

In other words, a stock that deviates either above or below it's market price will eventually revert back to it's historical mean. We can visualize this using continuous time-series analysis otherwise known as Orstein-Uhlenbeck process. We don't need to go into depth on the Orstein-Uhlenbeck process, but if you would like to know more see Wikipedia, and basic stochastic processes!

Ok, so now we know what a mean reversion is and why we are doing it. It helps us to understand if a stock is a buy or sell value based upon its current market price compared to its historical mean.

Now for the code: (mind you, this is in Python since we are using Quantopian.com).
**Any line that is preceded with a hashtag (#) and is underlined means that it is a 'comment'-comments are used within lines of code by the creator to define a process, or explain why he/she has done something. You do not need to include it in your code!

# Import the libraries we will use here
import numpy as np

**Ok, so import numpy as np is the coding package we are using in our Python module. This allows us to use certain commands as tools and helps us build the algorithm we intend to build!**

# The initialize function is the place to set your tradable universe and define any parameters. 
def initialize(context):
    # Use the top 1% of stocks defined by average daily trading volume.
    set_universe(universe.DollarVolumeUniverse(99, 100))

  # Set execution cost assumptions. For live trading with Interactive Brokers 
    # we will assume a $1.00 minimum per trade fee, with a per share cost of $0.0075. 
    set_commission(commission.PerShare(cost=0.0075, min_trade_cost=1.00))
   
    # Set market impact assumptions. We limit the simulation to 
    # trade up to 2.5% of the traded volume for any one minute,
    # and  our price impact constant is 0.1. 
    set_slippage(slippage.VolumeShareSlippage(volume_limit=0.025, price_impact=0.10))
**NOTE: slippage defines how your algorithm will impact the price of the security. As a participant in the market, you will have a small impact on prices depending on how you buy or sell.

    # Define the other variables
    context.long_leverage = 0.5
    context.short_leverage = -0.5
    context.lower_percentile = 20
    context.upper_percentile = 80
    context.returns_lookback = 5

  # Rebalance every Monday (or the first trading day if it's a holiday).
    # At 11AM ET, which is 1 hour and 30 minutes after market open.
    schedule_function(rebalance,
                      date_rules.week_start(days_offset=0),
                      time_rules.market_open(hours = 1, minutes = 30))

# The handle_data function is run every bar.  
def handle_data(context,data):  
    # Record and plot the leverage of our portfolio over time. 
    record(leverage = context.account.leverage)

    # We also want to monitor the number of long and short positions 
    # in our portfolio over time. This loop will check our positition sizes 
    # and add the count of longs and shorts to our plot.
    longs = shorts = 0
    for position in context.portfolio.positions.itervalues():
        if position.amount > 0:
            longs += 1
        if position.amount < 0:
            shorts += 1
    record(long_count=longs, short_count=shorts)

# This rebalancing is called according to our schedule_function settings.    
def rebalance(context,data):
    # Get the last N days of prices for every stock in our universe.
    prices = history(context.returns_lookback, '1d', 'price')
   
    # Calculate the past 5 days' returns for each security.
    returns = (prices.iloc[-1] - prices.iloc[0]) / prices.iloc[0]
   
    # Remove stocks with missing prices.
    # Remove any stocks we ordered last time that still have open orders.
    # Get the cutoff return percentiles for the long and short portfolios.
    returns = returns.dropna()
    open_orders = get_open_orders()
    if open_orders:
        eligible_secs = [sec for sec in data if sec not in open_orders]
        returns = returns[eligible_secs]

    # Lower percentile is the threshhold for the bottom 20%, upper percentile is for the top 20%.
    lower, upper = np.percentile(returns, [context.lower_percentile,
                                           context.upper_percentile])
   
    # Select the X% worst performing securities to go long.
    long_secs = returns[returns <= lower]
   
    # Select the Y% best performing securities to short.
    short_secs = returns[returns >= upper]
   
    # Set the allocations to even weights in each portfolio.
    long_weight = context.long_leverage / len(long_secs)
    short_weight = context.short_leverage / len(short_secs)
   
    for security in data:
       
        # Buy/rebalance securities in the long leg of our portfolio.
        if security in long_secs:
            order_target_percent(security, long_weight)
           
        # Sell/rebalance securities in the short leg of our portfolio.
        elif security in short_secs:
            order_target_percent(security, short_weight)
           
        # Close any positions that fell out of the list of securities to long or short.
        else:
            order_target(security, 0)
           
    log.info("This week's longs: "+", ".join([long_.symbol for long_ in long_secs.index]))
    log.info("This week's shorts: "  +", ".join([short_.symbol for short_ in short_secs.index]))



Ok, so run the code over at Quantopian.com or go ahead and run it through your own local Python IDLE and have a look at the results. 

If you're running it over at Quantopian.com and want to know the meaning of your results read here:

First, in the right hand side, you have your return; that is pretty self-explanatory, it is telling you how much you have made or lost given percentage of movement in the value of the stock.

Next we have alpha; alpha means 'a measure of performance on a risk adjusted basis' and additionally 'The abnormal rate of return on a security or portfolio in excess of what would be predicted by an equilibrium model like the capital asset pricing model (CAPM).' -http://www.investopedia.com/terms/a/alpha.asp

After alpha, we have beta which measures the volatility or risk.

After beta, we have 'Sharpe', which is the 'Sharpe ratio": it measures the risk-adjusted return. The Sharpe ratio is the average return earned in excess of the risk-free rate per unit of volatility or total risk.

Lastly, we have the drawdown: The peak-to-trough decline during a specific record period of an investment, fund or commodity. A drawdown is usually quoted as the percentage between the peak and the trough.

If you have any questions or concerns please send me an e-mail or post a comment!

Friday, January 8, 2016

Investing for Success: What to do in a down market

One of the scariest thing for a new, amateur investor or even those stock professionals who have been in the business for decades, is a sudden and sharp decline in stocks. Even worse for some folks and organizations who are heavily weighted in stocks, is a long-term decline in overall stock market.

Right now, the stock market is in decline and has been for the past week since it hit it's peak of 17,720.98 on the December 29th, 2015. Since then a lot has happened, Saudi Arabia and Iran are facing their highest tensions in years, the Chinese stock market fell 7% in the first 15 minutes of trading on Monday and continues to decline, and OPEC continues to pump out oil production at the highest rates ever, even in a congested market!

The DJIA right now (as of this writing) is at 16,578. So stocks haven't recovered yet and it could take a month, if not more, before they rebound and normalize again. This is a great lesson in psychology, not so much out of a fearful sort of psychology in people's minds, but of great awareness of their environment (stocks). I am neglected going into detail about the fed rate hike because it frankly is minimal that it has not had an impact on stocks.

First, let's look at why stocks are on the decline here in the U.S.

-As previously mentioned, China. Chinese exports are slowing dramatically as world growth is likewise slowing, having the second largest economy in the world, China makes a huge presence on the world stage, especially when you take into account their manufacturing and heavy industry sectors which are by far the largest in world, producing everything from concrete and copper to IPhones and DVD's.
    But.... it's important to note that their stock market (the Shanghai Stock Exchange), is NOT a critical component of their economy, nor is it anything more than an indication of how part of their economy is doing based upon highly speculative trading. This is also NOT how U.S. stock exchanges, specifically the Dow Jones Industrial Average operates. The reason for the differences between the U.S. stock exchange and the Chinese, is that our stock exchange is much more robust and developed, it includes the health and wealth of nearly every large company in the U.S. and every one that has gone public, and with the interconnectivity of our finances and how tied-in our retirement plans such as our 401k's are to our utility of life, everything that happens in the stock market is of some value to someone somewhere, whether or not they think it matters at all.

In China, their stock exchange is not fully developed, not well connected, and their people simply couldn't care less, mostly because it is foreign to them as in it bears no brunt or effect on their daily lives. There are not nearly as many companies listed as in the U.S. and many of them have little foreign investment, even then a lot of them see highly subsidized contracts and help from the Chinese government, and even then their stocks and financial health are not directly linked to Chinese economic performance.

In conclusion to this piece; the Chinese stock market (Shanghai Exchange) is not important, we need not worry about it unless you are directly invested through it. It does not represent the health of the Chinese economy the same way the Dow Jones Industrial Average represents the health of the U.S. economy. So the investors that are freaked out about the Chinese drop in stocks probably already know this, but stocks are about speculation and spatial awareness so they are doing their good-duty of playing it cautionary and pulling out of U.S. companies who have direct links to Chinese manufacturing and investment. It's a safe, but unnecessary strategy.

Were going to look into what we can do as investors here in the U.S. to combat the contagion of fear and also were going to see what we can do to capitalize on the most recent series of events.

------------


GENERAL RULES TO LIVE BY AS AN INVESTOR IN A DOWN MARKET

1. Sit on it, and wait for stocks to rebound and normalize. It might take a week or a year, but they will rebound unless there is something catastrophic, or a series of catastrophes in a specific market you are invested in. Otherwise, just wait it out and use this time as an opportunity to direct your funds typically used for investing in stocks, into debt repayment. Now is a great time to put extra cash down towards repaying your student loans, credit card debt, home equity loans, car payments, etc. The biggest mistake I see from investors is fear and panic, don't be like them it's just a dumb, bad strategy to have.

Let's take a look at some stocks and see what's going on, and what industries have been affected the most.

CHSCP is currently trading at $30.60 with no movement for the day, down from their previous high this week of 30.91. The past week has seen a lot of volatility much like Tesla Motors (TSLA) but to a smaller degree, overall this would be a fun stock to watch. TSLA has seen a steady decline from $233 five days ago to $213 now, with a lot of volatility mixed in. McDonalds (MCD) has been all over the place, their last peak was two days ago with $119, then dropped to $115 and now they're at $116, however if you had held this stock for anymore than a year you would have seen the stock shoot from $93 to it's current $116. That's a fantastic return if you're a long-term investor, and one year is hardly long-term. What about Google? They were $750 five days ago and now down to $717. Their 52 week low is $486, and the 52 week high is $779... ridiculous returns on such a pricey stock!

Pretty much everything is down today. Every sector, industry, everything is down. Bad day for stockholders overall, but even in such a case stocks will rebound and within the market there are some gainers.

2. Short stocks. Shorting is not for everyone and takes a greater understanding of the markets and stock fundamentals then normal stock trading. If you're going to short, you had better be sure that your stock is indeed failing, or have some sort of insurance or hedge against it as most folks will do. In order to short, you must have extra cash laying around that you can put down in case things go bad, because you will need it for the broker depending on the outcome of the short.

3. Continue investing in specific companies through intensive research. This is the riskiest move to make in a down market and only for those investors who are willing to put in the time and research involved in making such a move. You can find gainers in the markets and jump in with the trend and hope the momentum will continue (risky) or go ahead and see if your research leads you to a company that is about to break from the herd and realize some gains.

Take today for example, the best performing stock was that of NGL Energy Partners (NGL) whose stock soared over 45%! But why? If you're thinking it had something to do with the commodities industry or the energy sector you would be wrong. Instead, they sold one of their assets for $350 million, in a move that apparently shook investors the right way. Meanwhile, the rest of the energy sector was mostly meh, not going anywhere and those that did went down. There were a few exceptions like Kinder Morgan (KMI) and others but most every sector overall was down significantly.

------------

Friday, November 13, 2015

Fed funds rate with Taylor Rule implied

Let's take a look at the fed funds rate with implied Taylor Rule


Calculated as follows:

Taken from the St.Louis Fed website.

This is part of a post from here that you can read about. I am wanting to clarify what he has posted here that I hope will help someone with a very basic understanding of economics.

Take a look at this chart:

We have a lot going on here. Let's look at each one individually:
1) Fed funds (black line): The fed funds line you see here is the interest rate at which banks trade with one another, over night, using funds provided by the federal reserve--which acts as a primary lender. Generally speaking, the funds held at the federal reserve are only for the most credit-worthy depository institutions, and not just any bank. The fed funds rate influences both monetary and financial policy, which affects employment, growth, and inflation.

Currently, the federal reserve has been hinting at a rate hike, taking rates from near zero where they currently are to whatever number they want. It is most likely that they will increase the rate in small intervals so as not to shake the economy anymore than necessary. With an increase in the fed funds rate, generally speaking, comes at collapse, or at least modest decline in stocks; both price and volume, but is seen as a boon for bonds. Also, if you're an avid old-school saver, you will receive a higher interest rate on your bank deposits.

2) We have the Taylor Rule (red line): First, the Taylor Rule is a prediction here; predicting that when inflation is at target and the output is at potential (the output gap is zero), the FOMC will set the real federal funds rate at 2%, (the historical average), in this example 2.5%. The Taylor Rule is a guideline whose purpose is to describe the interest rate decisions of the FOMC.

The Taylor Rule was developed by Stanford economist John Taylor, which he describes it as being used as a "benchmark for monetary policy".

Here is the formula: r = p + .5y + .5(p – 2) + 2 (the “Taylor rule”)

where
r = the federal funds rate
p = the rate of inflation
y = the percent deviation of real GDP from a target

So on this it is important to explain that the feds target for real GDP is potential output; the amount the economy can sustainably produce when capital and labor are fully employed.

Looking at variably y in the Taylor rule, we can interpret it as being the excess of actual GDP over output, thus giving us the "output gap".

Using the Taylor Rule will lead us to predict that the FOMC will increase the fed funds rate (tightening of monetary policy) by one half of a percentage point (0.5%). It also predicts that when inflation is at target and output is at potential, the FOMC will set the real fed funds rate at 2%.



 This figure shows how monetary policy was too weak relative to using the Taylor rule for periods 2003-2005 and 2011. How do we know? By comparing the fed funds rate to the Taylor Rule, we see that the fed funds rate fell below the Taylor rule during those periods. Is that a good or bad thing? Well, mostly it doesn't matter, also this chart is from 2011, but I thought it both useful and interesting to use as we can see how the Brookings institute predicted the fed funds rate four years ago in comparison the the actual fed funds rate and the zero bound defined by the solid line.


3) Next, referring back to our second figure, we have the Taylor rule Laubach-Williams natural rate, the natural rate is assumed to change over time due to various unobservable influences.

4) The Wu-Xia shadow fed funds rate is not bounded below by zero percent, unlike many short-term models. In other words, it models what the fed funds rate would do negative interest rates were possible, using a host of historical macroeconomic data.

So now you're probably wondering what the heck all these models are doing on the same graph!?! It's simply giving us a comparison of what each model looks like given the same inputs. I like the Wu-Xia shadow myself, where it shows fed funds rates actually falling negative because it can be argued that it gives us a more accurate picture of whats going on in terms of monetary policy. That said, it, like many other models in economics can be argued against as well. It is currently not the model of choice for most economists, especially the feds, but it is considered a powerful representation of current macro policy; i.e. it's not as revered as the Taylor rule.

And finally, putting everything together, what does this tell us? This tells us that it is probably not the time for the feds to raise interest rates because the Laubach-Williams natural rate is 2.6% below the corresponding 2.5% equilibrium value derived on our Taylor rule (red) line.

Well I hope that was informative, if you have any questions please do not hesitate to ask!

Tuesday, November 10, 2015

The Experts vs. The Rest of Us

So finance is a science, right? Or is it an art? Either way, some individuals are clearly better at it than others. At least, in terms of money managers, investors, and analysts. Right? Well, I think it depends.

***My personal opinion**
From my experience in dealing with financial experts, and sort of being a "financial expert" myself ... that is without the incredible amount of wealth that normally seems to accumulate with most experts... I don't think there is much of a difference in the outcomes of an investors performance given their technical training (or lack there of). This extends beyond simple investing and into market forecasts and the prediction of large-scale economic events (such as a recession).

Check out these papers: here and here. To summarize both articles, they come to the conclusion that the experts are only "slightly" better at economic forecasting and at executing successful trades and investment decision making. There are actually more articles and papers on the subject that reinforce that statement that you can find through a Google search.

On an entirely theoretical scale, the reason why this seems to be the case is because markets are infamously tough to beat, and those that beat it, mostly beat it not because of any sort of magic, intensification of resources, or even because they're good at math and statistics; no. They beat the market because of two things: intuition, and guts.

Intuition may be attributable to some degree of luck, but you cannot make the argument that intuition itself is entirely luck, no. Most intuition comes from some level of knowledge of how markets work. Plain and simple. Maybe you have heard of Wave Theory, or maybe you haven't. A lot of folks I know have never heard of it yet, they're aware of it to some degree and that knowledge helps drive their investor sentiment. It helps guide them in what to buy, when, and for how long. These sorts of people notice trends before most other investors, and they also act much quicker than a similar person with an equal amount of knowledge, you might call it courage, fortitude, drive, whatever. The point is they are not afraid of execution.

That is most of investing.

Having spent most of my life working with math, especially the last seven years of it to very complex mathematical formulas and models, I can say with some degree of certainty that most successful investment strategies are more-so the product of intuition than they're good math. I can tell you what the price of a security should be, and how it should act under various situations and economic conditions, but I cannot tell exactly what will happen, even with perfect knowledge one slight change in a single variable will distort the entire investment environment.

That said, knowing the math can help. A great example of someone who is good with both math and at calling big economic events is Robert Schiller. But for everyday investment decision-making and money management, you don't need a highly polished educational background or to understand stochastic processes; no. You can simply observe trends, talk to your neighbors, and watch the news.

Again, these are my personal opinions based on my experience and knowledge. Feel free to prove me wrong with any number of papers and empirical facts, I would love that because I have yet to find any such paper.

Tuesday, August 25, 2015

Rate hike?!

Are rate hikes coming soon?

The folks at the federal reserve, including the head, Janet Yellen, would have you think so.

First, if a rate hike comes it will likely come in either September or December as those are the only two months that the federal reserve has scheduled press conferences. They have a meeting in October however there is no press conference scheduled for that time and quite frankly if you're going to be hiking rates you pretty much have to have a press conference.

After the recent turmoil in the markets, September could be too soon as the markets will not have had enough time to recover. December is also unlikely because liquidity tends to dry up at that time of year. According to some analysts, October could actually be the time to raise rates after-all.

Raising rates before December is increasingly likely, amidst the downturn in the recent bull-market. Why? Because of credibility. If the fed is going to maintain any credibility then they will have to stick by their previous statements and hike rates before years' end, and as mentioned earlier, December is not likely.

Global equity markets have lost $5 trillion in value over the last two weeks!-On expectations of slowing economic growth.

*remember, Yellen has indicated that any rate hike decision would be made without regard for scheduled press conferences!

Turning to the recent sell-off in US stocks which is to be blamed on the slowing of China's economy, the devaluation of the yen (which was China's attempt at reversing the recent slow-growth) and the lack of faith in the Chinese government to adequately control the housing bubble that has been growing for the last decade.

Here is Citi Banks' economist William Lee's comment: "If he (Fed Vice Chair Stanley Fischer) shows signs of worrying that the transitory downward pressures (commodity and energy prices and the appreciating dollar) are feeding through and becoming entrenched in wages and domestic prices—THAT would be a big event," the economist writes. "His concern would suggest reduced confidence in reaching the Fed inflation target in the medium term."