\begin{tikzpicture}[node distance=1cm and 1.5cm]
    \node[]at (0,0) (e1){$G_0$};
    \node[]at(1.75,-1.75) (aux1){};
    \shade[ball color=red] at (1.0,1.0) circle(0.2) {scat1};
    \draw[path] (e1) -- (aux1);

is giving error:

! Use of \@next doesn't match its definition.
\beamer@doifinframe ... \shade [ball color=red] at
                                                   (1.0,1.0) circle(0.2) {sc...
l.11 \end{frame}

everything is fine, if i remove at () from shade, only its in wrong position

  • Can you also share the "everything is fine" version? Sep 29, 2017 at 13:55
  • Offtopic: you don't need "\usepackage{graphicx}" with beamer Sep 29, 2017 at 13:55
  • @samcarter: just remove at () part, and sphere is coming at e1.
    – BaRud
    Sep 29, 2017 at 13:57
  • As the answer shows, you're not supposed to use the at keyword in this context. at only applies to nodes, while \shade is similar to \fill. Sep 29, 2017 at 16:51

1 Answer 1


The code worked without the at, but with the (1.0,1.0) also needed to replace the \draw[path] by \path[draw] and remove the {scat1}.

Working code:

\begin{tikzpicture}[node distance=1cm and 1.5cm]
    \node at(0,0) (e1){$G_0$};
    \node at(1.75,-1.75) (aux1){};
    \shade[ball color=red] (1.0,1.0) circle(0.2);
    \path[draw] (e1) -- (aux1);

off-topic: graphicx is loaded with tikz too

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .