factors to keep in mind before investing