I would like to build macro environment for a Pie Chart that I have. So that I can use several times easily. I already have a code that produces Pie chart/Donut Chart. It would be a great if there would be macro for arc angle/size, colour, arc label, and label for a central circular node. I would appreciate all the help. Here, is my MWE:
\documentclass{article}
\usepackage{xcolor}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[font=\sffamily\bfseries\large, text=white, border/.style={line width=12mm}]
\foreach \angle/\colour/\name [remember=\angle as \first (initially 0)] in {40/blue, 90/cyan, 160/green!30!black, 200/green, 240/orange, 295/red!70, 360/teal}{
\draw[\colour, border] (\first:1.5cm)
arc[start angle=\first, end angle=\angle, radius=1.5cm];
\draw[white, line width=1mm] (\first:0.8)--++(\first:1.8);
}
\node[line width=1mm, draw, circle, minimum width=1.7cm, white, fill=blue!80] {A};
\node at (20:1.5cm) {A1};
\node at (62:1.6cm) {A2};
\node at (125:1.5cm) {A3};
\node at (180:1.5cm) {A4};
\node at (221:1.5cm) {A5};
\node at (268:1.5cm) {A6};
\node at (330:1.5cm) {A7};
\end{tikzpicture}
\end{document}
This is the pie chart my code is producing at this moment.

