Is it possible to have it so that the plot marks would be filled and drawn, but the actual path wouldn't be drawn?
Here is example where it is otherwise the way I'd like, except those dots' should be filled with white:
\input tikz
\usetikzlibrary{shapes.geometric,plotmarks,scopes}
\tikzpicture[bend right, out=60, in=120, max distance=1.5cm]
\foreach \x in {1,...,8} {
\coordinate (n\x) at (\x,0);
}
\draw (n1) to (n3) to (n5) to (n7) to (n1);
\draw (n8) to (n6) to (n4) to (n2) to (n8);
\path plot[fill=white,draw=black,mark=*]
coordinates{(1,0) (2,0) (3,0) (4,0) (5,0) (6,0) (7,0) (8,0)};
\endtikzpicture
And here the dots are the way I would like, but the path is (of course) drawn:
\input tikz
\usetikzlibrary{shapes.geometric,plotmarks,scopes}
\tikzpicture[bend right, out=60, in=120, max distance=1.5cm]
\foreach \x in {1,...,8} {
\coordinate (n\x) at (\x,0);
}
\draw (n1) to (n3) to (n5) to (n7) to (n1);
\draw (n8) to (n6) to (n4) to (n2) to (n8);
\filldraw[fill=white,draw=black] plot[mark=*]
coordinates{(1,0) (2,0) (3,0) (4,0) (5,0) (6,0) (7,0) (8,0)};
\endtikzpicture
Is there a way to combine the two so that the dots look like in the latter, and the paths like in the former?
Best Answer
You have to supply the
fill
only to the markers. You can do that usingmark options={fill=white}
: