If you are an investor in financial instruments like stocks, bonds, options and derivatives, the most important thing to remember is: There Is No Stock Market.
When we talk loosely of "the stock market," it is not a problem as long as we keep in mind the reality underlying this terminology.
A stock market can be defined as a marketplace where stocks are bought and sold. Such stock markets exist. When I first visited New York City, in the 1970s, stock markets were not much different than they had been in the Netherlands in the 1400's or on Wall Street in the 1800's, except in scale. You could walk to a physical location like the New York Stock Exchange, literally on Wall Street, and watch a bunch of men (and I mean male humans) yelling, cryptically offering to buy or sell stock from each other, furiously writing down any transaction actually agreed upon.
Now most stocks and other financial instruments are traded electronically, with men in pits just an anachronism. Even during the men in pits era people began referring to indexes like the Dow Industrials or the S&P 500 as being "the market." It simplified things. Did the market go up or down today, this week, this year? Just look at the Dow numbers.
Stock prices, which represent the value of shares of individual companies, do have a loose tendency to go up and down together as a group. But the market being up or down, or flat, is a result of a summation and averaging process. Individual stocks that are included in the averages drive the indexes up and down, not the other way around [with the exception of index funds, which are obligated to buy or sell all the stocks in an index in the same proportion as they are represented in the index].
Individual stocks, in turn, go up and down depending on what bids there are to buy and sell their shares. People (and institutions they control) buy and sell shares all the time for all sorts of reasons.
If you want there to be a stock market for trading purposes you can buy an index fund. There are some powerful reasons for ordinary investors to buy index funds rather than individual stocks or managed mutual funds that in turn try to beat the indexes by buying and selling individual stocks.
Long ago certain traders and economists noticed that stock market movements (both pricing of individual stocks and of market averages) tend to be random over most periods of time. Take that observation as an ultimate truth and anyone who beats or is beaten by "the market" is simply a statistical variation, a lucky or unlucky gambler. Of those investors that do not exactly match the market average, half will to better than average and half worse than average over a given period of time. [For fuller arguments of this viewpoint see A Random Walk Down Wall Street by Burton G. Malkiel, Fooled by Randomness by Nassim Nicholas Taleb, or for a more analytic presentation Pricing the Future by George G. Szpiro]
Generally people buy a stock because they expect to make a profit on the investment. They may receive dividends, and the stock may go up in value over time. But most stocks most of the time are held by institutions, like pension funds and trust funds and 401k accounts. In other words, other people's money, which lessens the incentive to maximize returns. When stocks are bought and sold a commission (broker's fee) is generated, so there are individuals and institutions out there that encourage buying and selling for its own sake, which hurts returns which also adds to randomness.
Still, basic principles of investment apply. If a person buys the stock of an individual company and the price paid is less than the stream of future profits the company will generate, over time the investor will be rewarded with stock price appreciation and perhaps dividends. If a person buys a the stock of an individual company and the price paid is more than the stream of future profits the company will generate, over time the investor will see the price deteriorate.
By understanding the specifics of a company, including its culture, intellectual property, the profit margins that are "natural" for the particular business, and its position versus any competition, it is possible to be right more often than wrong about future profit streams.
Because sometimes unexpectedly bad things happen to good companies, and unexpectedly good things happen to bad (or at least mediocre) companies, most investors spread out there investments over a variety of companies.
In the Random Markets theory information spreads rapidly, so that anyone who cares to can know the prospects of any given company. This theory breaks down badly in reality. Most people don't know enough about business, or specific kinds of businesses, to do a good analysis themselves. Most are not willing to take the time to research a bunch of companies just to find a few gems. So most people trust specialists, ranging from the analysts of major Wall Street brokerage houses (sell-side analysts), to financial advisors and brokers, to tip-sheet writers, to poorly paid Internet journalists.
All these professionals charge money, one way or another, for their services. And they should: it takes time to research stocks and it takes marketing dollars to land clients, and then there are costs of operations. Despite that, on average they get an average return on the portfolios they create. So you can do better (unless you are one of the lucky people who gets an exceptional broker or financial advisor) by going to a low-cost Internet-based broker and buying stock-index funds.
Now suppose you are like me and think you can outsmart the professionals, including the Wall Street analysts (who after all mostly go straight from college or an MBA program into these positions with little real life or actual experience in business). I believe that if you can be unemotional, and do your homework, you can beat the averages, because I have done it.
The most important thing to remember, as you learn to spend long hours reading SEC documents and commentaries like mine at places like Seeking Alpha, is not that there is always a lot of pump-and-dump activity going on from penny stocks all the way up to Dow Industrials (and the reverse, short and trash activity). Although you should keep that in mind.
You should not care what the Dow did on any given day, or month, or year. Or, if you are like me, what the NASDAQ-100 did [most of my stock picks are from that index]. Except maybe as a benchmark for seeing if your strategy, or your picks, are doing better than the index funds.
There Is No Stock Market! There are only individual companies, and prices quoted through an auction system on a minute-by-minute basis. News may effect a stock's price on any given day, including news about the company's audited financial numbers for a quarter, but the only thing that really matters is the future stream of profits (that could be, but usually are not, doled out to the shareholders).
Do not hope for "the market" to bail out your bad choices, just because that has happened at times. The best way to get in trouble is to think that other fools are going to bid up a stock when there is no foundation for its price. If you own a stock that you cannot justify by coldly analyzing its potential for profits, you are the fool.
Down markets, when people panic and sell without discretion, as happened in 2008, are your friend. You should have cash to buy bargains because you sold overpriced stocks before the bust. But just because a company's price has fallen, even substantially, does not mean it is a good buy. Take your time and sort through the wreckage for the gems.
When you keep researching stocks and most seem to be priced higher than you can justify, revisit your holdings, because they may have risen to a point that can no longer be justified. But again, just because a stock went up does not mean you should sell it. The question to ask is: Why did the stock go up? If it was enthusiasm of newcomers, rather than because prospects for profit growth are still great, it is likely time to trade in that stock for cash.
While this advice is too general to help you select individual stocks, it is something to always keep in mind. Wall Street professionals tend to forget it. They get caught up in their own hype (which can include hyping certain stocks down, although most hype is in the upward direction).
There is no stock market, but being contrary is not in itself a strategy. If you go contrary to the sell-side Wall Street brokerage recommendations, be sure to have a very good reason for doing so. Some not-sufficiently good reasons: a guru recommended the stock. A relative recommended a stock. A financial advisor recommended a stock. Etc.
There is no stock market. There are only averages. If average is okay for you, invest in index funds. Baring the apocalypse, profits grow over time, and index funds grow over time. If you did not sell at the top, or at least half-way down, it is idiotic to sell at the bottom.
And keep diversified!