What is one indication that a planet may exist near a distant star?

If a distant star has a slight back and forth motion then it may be located near a planet. The gravitational force of the planet will cause the star to move.