Place the duck on a wire rack set over a large roasting tin. Pour a full kettle of boiling water evenly over the duck to tighten the skin.
Allow the duck to cool, then pat it completely dry with kitchen paper.
Season the duck generously inside and out with salt and pepper.
Fill the cavity with the mandarin, onion, cinnamon stick, star anise and cranberries.
Roast the duck in the middle of a preheated oven at 200°C (375°F) for 20 minutes.
Turn the duck over and roast for another 20 minutes, until the skin is beginning to turn golden.
Carefully drain off the rendered fat from the roasting tin, then pour in the cranberry juice.
Reduce the oven temperature to 165°C. Turn the duck breast-side up and roast for about 1 hour, until deeply golden and cooked through. Cover loosely with foil if it browns too quickly.
While the duck is roasting, make the glaze: simmer the marmalade and cranberry juice together until reduced to a thick, glossy syrup. Add a splash of orange liqueur if using.
Brush the duck generously with the glaze and return it to the oven for 15–20 minutes, until richly coloured. Keep a close eye to prevent burning.
Remove the duck from the oven, cover loosely with foil and rest for at least 25 minutes, wrapped in kitchen towels or blankets to keep warm.
Carve and serve with your chosen side dishes.