AMHERST, Mass.—Federal Reserve Chairwoman Janet Yellen argued the case for raising short-term interest rates later this year, effectively lobbing a warning to skittish financial markets that last week’s decision to keep rates near zero wasn’t a shift toward an interminable delay of liftoff.

Ms. Yellen, setting out to build a case like a prosecutor giving a closing argument, presented a 40-page speech in a cavernous auditorium at the University of Massachusetts in Amherst. Thursday’s speech included 40 academic citations, 35...