The plant, which employs 4,000 people, is an example of how deeper ties between the United States and Africa could produce good jobs and boost economic growth for both sides, Yellen told workers and company officials.

"Africa will shape the future of the global economy," she said. "We know that a thriving Africa is in the interest of the United States. A thriving Africa means a larger market for our goods and services. It means more investment opportunities for our businesses."

About 600 U.S. companies operate in South Africa, employing about 220,000 people and generating revenue equivalent to about 10% of South Africa's entire gross domestic product, U.S. Ambassador to South Africa Reuben Brigety said at the event.