# How do I flip/rotate a resistor in CircuiTikZ?

How can I flip a resistor in CircuiTikZ?. Some thing like a , or

rotate = 180


or

yscale = -1


but for a resistor.

In other words my resistors looks like this:

and I am trying to make it look like this:

How can I do this?

I have tried using the rotate, yscale commands, but to no avail. I have also tried doing this part of the circuit from left to right and from right to left but that didn't do it either...

• [mirror image] or [invert] (see page 166). Invert is more use for things with polarity. Commented Apr 4, 2021 at 18:26

You can use mirror (vertical axis) or invert (horizontal, that in this case does the same, because the shape is symmetric).

\documentclass[border=10pt]{standalone}
\usepackage[siunitx, RPvoltages]{circuitikz}
\begin{document}
\begin{tikzpicture}[]
\draw (0,1) to[R] ++(2,0);
\draw (0,0) to[R=mirror, mirror] ++(2,0);
\draw (0,-1) to[R=invert, invert] ++(2,0);
\end{tikzpicture}
\end{document}


yscale and xscale, as well as rotate, are not supposed to work inside a to[] command. They will work on the node shape:

\documentclass[border=10pt]{standalone}
\usepackage[siunitx, RPvoltages]{circuitikz}
\begin{document}
\begin{tikzpicture}[]
\node [resistorshape](r1) at (0,1) {};
\node [resistorshape, yscale=-1](r0) at (0,0) {};
\end{tikzpicture}
\end{document}


• Thank You so so much!!!. Been searching online for hours and couldn't find anything. Also figured out why I wasn't able to draw a resistor node standalone (was trying to do \node [resistor]), but it's actually \node [resistorshape]. Thanks a lot once again! Commented Apr 4, 2021 at 19:14
• You're welcome. There is a section in the manual called "flipping and mirroring" ;-) Commented Apr 4, 2021 at 20:31