It may not be such a good idea. A perfect market timer could have, over the last 80 years, turned $1 into $670 million. A perfectly inept market timer would have turned $100 million into $1,000. A market timer would have to be right about 70% of the time just to equal the return of a buy and hold index fund. Do you think you are that good? See the study here