Maybe missing a "\usepackage{tikz}"?
(That caught me out)

--
Martin Schöön