In the United States, the names are used interchangeably. They are, however, two completely different products. A true yam is a starchy edible root (Dioscorea species) imported from the Caribbean. Yams have brown, rough, scaly skin with whitish flesh, are very low in beta-carotene, and have a dry texture.
What is known as a yam in the United States is actually a sweet potato. Sweet potatoes (Ipomoea batatas) have a distinctive orange color, soft texture when cooked, and a sweet flavor. The skin is smooth and thin, and depending upon the variety, the skin color can be pale yellow, deep orange, or deep purple. The flesh color can be light yellow, orange, pink, or red.
How did this confusion start? Years ago, the orange sweet potato was introduced into the southern United States. To differentiate it from the white-fleshed varieties, the African-American name "nyami" was implemented. In English, nyami means yam. The United States Department of Agriculture requires that the sweet potato be labeled both "yam" and "sweet potato."