I'd like to create an antenna radiation pattern in the form of a polar plot like this one:
(image credits: C.A. Balanis; Antenna theory, analysis and design)
What I've done so far is the following code (the data file to make the example work is here):
\documentclass{standalone}
\usepackage{pgfplots}
\begin{document}
\begin{tikzpicture}
\begin{axis}[
data cs=polar,
% restrict x to domain=0:180,
% restrict y to domain=0:180,
ymin=-90,
ymax=90,
zmax=10.8,
]
\addplot3[surf,fill=white] table[x index={1},y index={0},z index={2}]{subarray-3d-plot-dir.csv};
\end{axis}
\end{tikzpicture}
\end{document}
but, strangely, pgfplots
closes the paths between the first and the last point, as can be seen by the resulting image:
My questions:
- how to remove the segments that close the paths?
- how to improve the mesh/surface?
Clarification: the data file comes from a simulation software, so I don't have any means to change the way data are written in it.