TikZ-PGF – How to Create Figures Like Coordinate Systems in TikZ Efficiently

coordinatesdiagramsgraphicstikz-pgf

I am new to LaTex and Tikz Package. I am trying to create figures in Tikz (which was recommended to me in my previous question). This is what I had made after days of tinkering. However, I made this figure for two days, which is time-consuming. I am wondering if there is a better way to do it? And what are the essential things to keep in mind when creating figures? I can't seem to understand what is going on. I highly appreciate any guidance given to me.

Code:

\begin{figure}[H]
\begin{center}
\begin{tikzpicture} [scale=0.7]

%Coordinate System
\draw[-{Latex[width'=5pt 0, length=5pt]}] (-5,0) -- (5,0); 
\draw[-{Latex[width'=5pt 0, length=5pt]}] (0,-5) -- (0,5);

%Angle
\coordinate (A) at (5,0);
\coordinate (B) at (0,0);
\coordinate (C) at (176:5) ;
\draw [-{Latex[width'=5pt 0, length=5pt]}] (0,0) -- (176:5);

%Arrow
\draw (A) -- (B) -- (C)
pic [draw=black, angle radius=30mm] {angle = A--B--C};


%Angle
\coordinate (A) at (176:5);
\coordinate (B) at (0,0);
\coordinate (C) at (180:5);

\draw (A) -- (B) -- (C)
pic [fill=green!25, draw=black, angle radius=30mm] {angle = A--B--C};
%Label
\draw (-3,-0.3) node [fill=white!100!black, scale=1]
{$4^{\circ}$};

\draw (0,3) node [fill=white!100!black, scale=1]
{$176 ^{\circ}$};

\end{tikzpicture}
\end{center}
\caption{Illustration of $176 ^{\circ}$ with its reference angle}
\label{fig:176}
\end{figure}

Output:

My own figure

This is the figure that I really wanted to create. It is from a paper by King et al. (2020) titled "Trigonometry: a brief conversation."

What I wanted

King, C., Evelyn, T., Ye, F., & Carvajal, B. (2020). Trigonometry: A Brief Conversation. Open Educational Resources. https://academicworks.cuny.edu/qb_oers/167/

Thank you in advance.

Best Answer

Values of angles written by quotes (on usual way) does not given very pleasant result. In this particular case seems to be more appropriate add them separately outside of pic macro. For example, as is done in the following MWE:

\documentclass[tikz,border=5mm]{standalone}
\usetikzlibrary{angles, arrows.meta,
                quotes}
\usepackage{siunitx}

\begin{document}
    \begin{tikzpicture}[
               > = {Straight Barb[scale=0.8]},
every pin/.style = {pin edge={<-,black}, font=\footnotesize},
 my angle/.style = {draw, <->,
                    angle radius = 30mm,
                    angle eccentricity=0.6,
                    font=\scriptsize}
                       ]
% coordinate system
\draw[-Stealth] (-4,0) coordinate (A')
                 -- (4,0) coordinate (A);
\draw[-Stealth] (0,-4) -- (0,4);
% coordinates
\coordinate (B) at (0,0);
\coordinate (C) at (176:4) ;
% vector
\draw[->, semithick]   (B) -- (C);
% Angle 4 degree
\pic [my angle, fill=green!25] {angle = C--B--A'};
\coordinate[pin=300:\qty{4}{\degree}] (aux)   at (178:2.8);
% Angle 176 degree
\pic [my angle] {angle = A--B--C};
\node   at (135:2.4) {\qty{176}{\degree}};
    \end{tikzpicture}
\end{document}

enter image description here

For the second image in your MWE, angle values write by use quotes package, gives nice rezult:

\documentclass[tikz,border=5mm]{standalone}
\usetikzlibrary{angles, arrows.meta,
                quotes}
\usepackage{siunitx}

\begin{document}
    \begin{tikzpicture}[
               > = {Straight Barb[scale=0.8]},
every pin/.style = {pin edge={<-,black}, font=\footnotesize},
 my angle/.style = {draw, <->,
                    angle radius = 30mm,
                    angle eccentricity=1.1,
                    font=\scriptsize}
                       ]
% coordinate system
\draw[-Stealth] (-4,0) -- (4,0) coordinate (A);
\draw[-Stealth] (0,-4) -- (0,4);
% coordinates
\coordinate (B) at (0,0);
\coordinate (C) at (240:4) ;
% vector
\draw[->, semithick]   (B) -- (C);
% Angle 240 degree
\pic [my angle, "\qty{240}{\degree}"] {angle = A--B--C};
% Angle 120 degree
\pic [my angle, "\qty{120}{\degree}"] {angle = C--B--A};
    \end{tikzpicture}
\end{document}

enter image description here