Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- documentclass[tikz,border=3mm]{standalone}
- usetikzlibrary{calc}
- usepackage{pgfplots}
- pgfplotsset{compat=1.15}
- usepgfplotslibrary{polar}
- usepackage{filecontents}
- begin{filecontents*}{radar.csv}
- angle,radius,class,name
- 130, 4, 1, a
- 348, 3, 1, b
- 212, 5, 2, c
- 56, 2, 2, d
- end{filecontents*}
- begin{document}
- begin{tikzpicture}
- begin{polaraxis}[
- width=8cm, height=8cm,
- visualization depends on={value thisrow{name} as labelname}
- ]
- addplot[
- scatter, only marks,
- point meta=explicit symbolic,
- mark options={
- text mark=labelname,
- text mark as node=true,
- text mark style={circle,inner sep=1pt,draw}
- },
- scatter/classes={
- 1={
- mark = text,
- mark options={
- text mark style={square,inner sep=2pt,draw}
- },
- blue
- },
- 2={
- mark = text,
- mark options={
- text mark style={*triangle}
- },
- red
- }
- }
- ]
- table[ x=angle, y=radius, meta=class, col sep=comma
- ] {radar.csv};
- end{polaraxis}
- end{tikzpicture}
- end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement