Preheat oven to 325º F. Cut sweet potatoes crosswise into 1/2-inch thick slices. Arrange half of potatoes evenly in a shallow 1-1/2 quart casserole. Top with apples, then with remaining potatoes. Set aside.
In a small microwave-safe bowl, combine dried cranberries, sugar, butter, and pumpkin pie spice. Microwave on high power 1 minute, or until butter is melted. Stir to blend.
Drizzle cranberry sugar mixture evenly over potatoes. Sprinkle with nuts, if desired. Cover and bake 1 hour.