Combine cranberries, orange slices, sugar, pecans, orange juice, cinnamon, nutmeg, and mace in a 2-quart baking dish.
Bake in preheated oven until cranberries soften, about 30 minutes. Stir yams into cranberry mixture and continue baking until heated through, about 15 minutes more.