Customizing Half Pie Chart Labels with tikzPackage for pie chartsDecimal values in polar pie chartPie Chart with datatoolLabels close to pie chart figuresHelp with pie chartPie chart with bar chart magnificationPie chart color problemPie Chart without labels in beamer using pgf-piePie Chart Doesn't ClosePie chart labelsTikz - Pie chart with many data
Shall I use personal or official e-mail account when registering to external websites for work purpose?
Is std::next for vector O(n) or O(1)?
Supply current of negative rail
Is it legal to have the "// (c) 2019 John Smith" header in all files when there are hundreds of contributors?
Was there ever an axiom rendered a theorem?
How would photo IDs work for shapeshifters?
Why can Shazam fly?
Is it wise to focus on putting odd beats on left when playing double bass drums?
Is it possible to build an equivalent function just looking at the input and output of the original function?
Is this food a bread or a loaf?
Can I find out the caloric content of bread by dehydrating it?
What is the steepest angle that a canal can be traversable without locks?
Are white and non-white police officers equally likely to kill black suspects?
Landlord wants to switch my lease to a "Land contract" to "get back at the city"
I see my dog run
What does "rabbited" mean/imply in this sentence?
Is it worth rebuilding a wheel myself to save money
If a centaur druid Wild Shapes into a Giant Elk, do their Charge features stack?
Access elements in std::string where positon of string is greater than its size
"My colleague's body is amazing"
Why is the design of haulage companies so “special”?
Why is my log file so massive? 22gb. I am running log backups
What do the Banks children have against barley water?
Dual Citizen. Exited the US on Italian passport recently
Customizing Half Pie Chart Labels with tikz
Package for pie chartsDecimal values in polar pie chartPie Chart with datatoolLabels close to pie chart figuresHelp with pie chartPie chart with bar chart magnificationPie chart color problemPie Chart without labels in beamer using pgf-piePie Chart Doesn't ClosePie chart labelsTikz - Pie chart with many data
There's a nice answer to a pie chart question over here. I tried to bend it to my needs but found some aspects difficult. Specifically:
I'd like to be able to manually adjust the labels.
Rather than adding the degree labels
(newcommanddegre$^circ$
, I assume), I just want to be able
to write something in manually, like a year or date or note or the
variable name for instance.I'd liked to have the option of replacing the percentage labels with
something else too, like the actual value shown in the legend
perhaps.And finally, the numbers aren't formatted nicely. For instance, the
value1236
should ideally be written as1,236
.
Is this kind of customization possible? There are various similar questions about other pie chart designs, but this design is a bit different to most I've seen. Anyway the current code is below.
PS: I kept getting lost in it, so to make reading a bit quicker and easier, I've set:begindocument
through enddocument
in bold, and:value list=149/A,1236/R+L+D,740/N+F,346/C,75/E
in italics, so you can identify it at a glance.
documentclass[margin=5pt]article
usepackage[svgnames]xcolor
usepackagetikz,fourier,ifthen
usetikzlibrarycalc
newcommanddegre$^circ$
colorletcolor0blue!40
colorletcolor1orange!60
colorletcolor2DarkGreen!40
colorletcolor3yellow!60
colorletcolor4red!60
colorletcolor5blue!60!cyan!60
colorletcolor6cyan!60!yellow!60
colorletcolor7red!60!cyan!60
colorletcolor8red!60!blue!60
colorletcolor9orange!60!cyan!60
makeatletter
tikzset%
dc tag/.style=align=center,
dc legend/.style=align=left,anchor=west,
dc sector/.style=fill=Cj,line join=round
pgfkeys/DiagCirc/.cd,
% list of Name/Value
value list/.store in=Value@list,
% circular : 360 - semi circular 180
angle max/.store in=Angle@max,
angle max=360,
% radius of the diagram
radius/.store in=R@dius,
radius=4cm,
% composition of the legend
% V value
% N name
% P percent
% A angle
% Cj color
legend/.store in=L@gend,
legend=,
% location of the legend
legend location/.store in=Legend@Loc,
legend location=($(R@dius,R@dius)+(.5,-.5)$),
% poisition of the node in the sector
% 0 center, 1 on the edge, 1.++ external
factor/.store in=F@ctor,
factor=.80,
% composition of the node in the sector
tags/.store in=T@gs,
tags=,
% correction of round errors in percents
percent corr/.store in=C@rrP,
percent corr=,
% correction of round errors in angles
angle corr/.store in=C@rrA,
angle corr=,
% individual shift
shift sector/.store in=Shift@j,
shift sector=,
% more nodes in the sectors, or new legeng
sup loop/.store in=Sup@Loop,
sup loop=,
% code of the diagram
diagram/.code=%
% Calculation of the sum
pgfmathsetmacroS@m0
foreach i/y in Value@list xdefS@mS@m+i
pgfmathsetmacroS@mS@m
pgfmathsetmacroC@effAngle@max/S@m
% beginning of the first sector
xdef@ngleA0
% main loop
foreach V/N [count=j from 0] in Value@list %
% calculation of the current angle
pgfmathsetmacroAV*C@eff
% superior limit of the sector
pgfmathsetmacro@ngleB@ngleA+A ;
% mean angle
pgfmathsetmacroMedA(@ngleA+@ngleB)/2 ;
% color
pgfmathtruncatemacro@kmod(j,10)
defCjcolor@k
% individual shift
ifthenelseequalShift@j%
edefSh@ft0%
pgfmathparsearray(Shift@j,j)
edefSh@ftpgfmathresult
% drawing of the sector
draw[dc sector,shift=(MedA:Sh@ft)] (0,0)
-- (@ngleA:R@dius) arc (@ngleA:@ngleB:R@dius)
node[midway] (DCj) -- cycle ;
% low limit of the next sector
xdef@ngleA@ngleB ;
% current percent correction
pgfmathtruncatemacroPround(V/S@m*100)
ifthenelseequalC@rrP%
pgfmathparsearray(C@rrP,j)
pgfmathtruncatemacroPP+pgfmathresult
edefPP,%
% current angle and corection
pgfmathtruncatemacroAround(A)
ifthenelseequalC@rrA%
pgfmathparsearray(C@rrA,j)
pgfmathtruncatemacroAA+pgfmathresult
edefAA,degre
% the sector node
ifthenelseequalT@gs%
DiagNode[dc tag]F@ctor T@gs ;
% the legend
ifthenelseequalL@gend%
beginscope[shift=Legend@Loc]
draw[fill=Cj] (0,-.5*j)
rectangle ++(.25,.25) ++(0,-.15)
node[dc legend] strutL@gend ;
endscope
% some more stuff
Sup@Loop ;
% end of diagram code
makeatother
% Node on the j sector
newcommandDiagNode[2][]node[#1] at ($(0,0)!#2!(DCj)$)
begindocument
begintikzpicture
path[%
% style options
dc sector/.append style=shift=(MedA:5pt), % shift all sectors
dc dtag/.append style=,
dc legend/.append style=text width=2cm, align=right,
every pin/.style=fill=Cj,draw=Cj!50!black,thick,
% diagram options
/DiagCirc/.cd,
value list=149/A,1236/R+L+D,740/N+F,346/C,75/E,
angle max=180, % semi-circular
angle corr=0,1,0,0,0, % correct round angle error
legend=N :hfill V, % custom legend
factor=.9,
percent corr=0,-1,0,0,0, % correct round percent error
shift sector=0,0,.3,0,0, % shift individual sector
tags=P, % custom sector nodes
sup loop=% custom features :
%DiagNode1.1 N; % some other sector nodes
% or something else
defPin10,40,150,120,150
pgfmathparsearray(Pin,j)
edefPinjpgfmathresult
node[pin=Pinj:A] at (DCj) ;
,
diagram] ;
endtikzpicture
enddocument
tikz-pgf diagrams charts pgf-pie
add a comment |
There's a nice answer to a pie chart question over here. I tried to bend it to my needs but found some aspects difficult. Specifically:
I'd like to be able to manually adjust the labels.
Rather than adding the degree labels
(newcommanddegre$^circ$
, I assume), I just want to be able
to write something in manually, like a year or date or note or the
variable name for instance.I'd liked to have the option of replacing the percentage labels with
something else too, like the actual value shown in the legend
perhaps.And finally, the numbers aren't formatted nicely. For instance, the
value1236
should ideally be written as1,236
.
Is this kind of customization possible? There are various similar questions about other pie chart designs, but this design is a bit different to most I've seen. Anyway the current code is below.
PS: I kept getting lost in it, so to make reading a bit quicker and easier, I've set:begindocument
through enddocument
in bold, and:value list=149/A,1236/R+L+D,740/N+F,346/C,75/E
in italics, so you can identify it at a glance.
documentclass[margin=5pt]article
usepackage[svgnames]xcolor
usepackagetikz,fourier,ifthen
usetikzlibrarycalc
newcommanddegre$^circ$
colorletcolor0blue!40
colorletcolor1orange!60
colorletcolor2DarkGreen!40
colorletcolor3yellow!60
colorletcolor4red!60
colorletcolor5blue!60!cyan!60
colorletcolor6cyan!60!yellow!60
colorletcolor7red!60!cyan!60
colorletcolor8red!60!blue!60
colorletcolor9orange!60!cyan!60
makeatletter
tikzset%
dc tag/.style=align=center,
dc legend/.style=align=left,anchor=west,
dc sector/.style=fill=Cj,line join=round
pgfkeys/DiagCirc/.cd,
% list of Name/Value
value list/.store in=Value@list,
% circular : 360 - semi circular 180
angle max/.store in=Angle@max,
angle max=360,
% radius of the diagram
radius/.store in=R@dius,
radius=4cm,
% composition of the legend
% V value
% N name
% P percent
% A angle
% Cj color
legend/.store in=L@gend,
legend=,
% location of the legend
legend location/.store in=Legend@Loc,
legend location=($(R@dius,R@dius)+(.5,-.5)$),
% poisition of the node in the sector
% 0 center, 1 on the edge, 1.++ external
factor/.store in=F@ctor,
factor=.80,
% composition of the node in the sector
tags/.store in=T@gs,
tags=,
% correction of round errors in percents
percent corr/.store in=C@rrP,
percent corr=,
% correction of round errors in angles
angle corr/.store in=C@rrA,
angle corr=,
% individual shift
shift sector/.store in=Shift@j,
shift sector=,
% more nodes in the sectors, or new legeng
sup loop/.store in=Sup@Loop,
sup loop=,
% code of the diagram
diagram/.code=%
% Calculation of the sum
pgfmathsetmacroS@m0
foreach i/y in Value@list xdefS@mS@m+i
pgfmathsetmacroS@mS@m
pgfmathsetmacroC@effAngle@max/S@m
% beginning of the first sector
xdef@ngleA0
% main loop
foreach V/N [count=j from 0] in Value@list %
% calculation of the current angle
pgfmathsetmacroAV*C@eff
% superior limit of the sector
pgfmathsetmacro@ngleB@ngleA+A ;
% mean angle
pgfmathsetmacroMedA(@ngleA+@ngleB)/2 ;
% color
pgfmathtruncatemacro@kmod(j,10)
defCjcolor@k
% individual shift
ifthenelseequalShift@j%
edefSh@ft0%
pgfmathparsearray(Shift@j,j)
edefSh@ftpgfmathresult
% drawing of the sector
draw[dc sector,shift=(MedA:Sh@ft)] (0,0)
-- (@ngleA:R@dius) arc (@ngleA:@ngleB:R@dius)
node[midway] (DCj) -- cycle ;
% low limit of the next sector
xdef@ngleA@ngleB ;
% current percent correction
pgfmathtruncatemacroPround(V/S@m*100)
ifthenelseequalC@rrP%
pgfmathparsearray(C@rrP,j)
pgfmathtruncatemacroPP+pgfmathresult
edefPP,%
% current angle and corection
pgfmathtruncatemacroAround(A)
ifthenelseequalC@rrA%
pgfmathparsearray(C@rrA,j)
pgfmathtruncatemacroAA+pgfmathresult
edefAA,degre
% the sector node
ifthenelseequalT@gs%
DiagNode[dc tag]F@ctor T@gs ;
% the legend
ifthenelseequalL@gend%
beginscope[shift=Legend@Loc]
draw[fill=Cj] (0,-.5*j)
rectangle ++(.25,.25) ++(0,-.15)
node[dc legend] strutL@gend ;
endscope
% some more stuff
Sup@Loop ;
% end of diagram code
makeatother
% Node on the j sector
newcommandDiagNode[2][]node[#1] at ($(0,0)!#2!(DCj)$)
begindocument
begintikzpicture
path[%
% style options
dc sector/.append style=shift=(MedA:5pt), % shift all sectors
dc dtag/.append style=,
dc legend/.append style=text width=2cm, align=right,
every pin/.style=fill=Cj,draw=Cj!50!black,thick,
% diagram options
/DiagCirc/.cd,
value list=149/A,1236/R+L+D,740/N+F,346/C,75/E,
angle max=180, % semi-circular
angle corr=0,1,0,0,0, % correct round angle error
legend=N :hfill V, % custom legend
factor=.9,
percent corr=0,-1,0,0,0, % correct round percent error
shift sector=0,0,.3,0,0, % shift individual sector
tags=P, % custom sector nodes
sup loop=% custom features :
%DiagNode1.1 N; % some other sector nodes
% or something else
defPin10,40,150,120,150
pgfmathparsearray(Pin,j)
edefPinjpgfmathresult
node[pin=Pinj:A] at (DCj) ;
,
diagram] ;
endtikzpicture
enddocument
tikz-pgf diagrams charts pgf-pie
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
PPS: Someone removed thepstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I thinktikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you usepstricks
or whatever, feel free.
– tjt263
12 mins ago
add a comment |
There's a nice answer to a pie chart question over here. I tried to bend it to my needs but found some aspects difficult. Specifically:
I'd like to be able to manually adjust the labels.
Rather than adding the degree labels
(newcommanddegre$^circ$
, I assume), I just want to be able
to write something in manually, like a year or date or note or the
variable name for instance.I'd liked to have the option of replacing the percentage labels with
something else too, like the actual value shown in the legend
perhaps.And finally, the numbers aren't formatted nicely. For instance, the
value1236
should ideally be written as1,236
.
Is this kind of customization possible? There are various similar questions about other pie chart designs, but this design is a bit different to most I've seen. Anyway the current code is below.
PS: I kept getting lost in it, so to make reading a bit quicker and easier, I've set:begindocument
through enddocument
in bold, and:value list=149/A,1236/R+L+D,740/N+F,346/C,75/E
in italics, so you can identify it at a glance.
documentclass[margin=5pt]article
usepackage[svgnames]xcolor
usepackagetikz,fourier,ifthen
usetikzlibrarycalc
newcommanddegre$^circ$
colorletcolor0blue!40
colorletcolor1orange!60
colorletcolor2DarkGreen!40
colorletcolor3yellow!60
colorletcolor4red!60
colorletcolor5blue!60!cyan!60
colorletcolor6cyan!60!yellow!60
colorletcolor7red!60!cyan!60
colorletcolor8red!60!blue!60
colorletcolor9orange!60!cyan!60
makeatletter
tikzset%
dc tag/.style=align=center,
dc legend/.style=align=left,anchor=west,
dc sector/.style=fill=Cj,line join=round
pgfkeys/DiagCirc/.cd,
% list of Name/Value
value list/.store in=Value@list,
% circular : 360 - semi circular 180
angle max/.store in=Angle@max,
angle max=360,
% radius of the diagram
radius/.store in=R@dius,
radius=4cm,
% composition of the legend
% V value
% N name
% P percent
% A angle
% Cj color
legend/.store in=L@gend,
legend=,
% location of the legend
legend location/.store in=Legend@Loc,
legend location=($(R@dius,R@dius)+(.5,-.5)$),
% poisition of the node in the sector
% 0 center, 1 on the edge, 1.++ external
factor/.store in=F@ctor,
factor=.80,
% composition of the node in the sector
tags/.store in=T@gs,
tags=,
% correction of round errors in percents
percent corr/.store in=C@rrP,
percent corr=,
% correction of round errors in angles
angle corr/.store in=C@rrA,
angle corr=,
% individual shift
shift sector/.store in=Shift@j,
shift sector=,
% more nodes in the sectors, or new legeng
sup loop/.store in=Sup@Loop,
sup loop=,
% code of the diagram
diagram/.code=%
% Calculation of the sum
pgfmathsetmacroS@m0
foreach i/y in Value@list xdefS@mS@m+i
pgfmathsetmacroS@mS@m
pgfmathsetmacroC@effAngle@max/S@m
% beginning of the first sector
xdef@ngleA0
% main loop
foreach V/N [count=j from 0] in Value@list %
% calculation of the current angle
pgfmathsetmacroAV*C@eff
% superior limit of the sector
pgfmathsetmacro@ngleB@ngleA+A ;
% mean angle
pgfmathsetmacroMedA(@ngleA+@ngleB)/2 ;
% color
pgfmathtruncatemacro@kmod(j,10)
defCjcolor@k
% individual shift
ifthenelseequalShift@j%
edefSh@ft0%
pgfmathparsearray(Shift@j,j)
edefSh@ftpgfmathresult
% drawing of the sector
draw[dc sector,shift=(MedA:Sh@ft)] (0,0)
-- (@ngleA:R@dius) arc (@ngleA:@ngleB:R@dius)
node[midway] (DCj) -- cycle ;
% low limit of the next sector
xdef@ngleA@ngleB ;
% current percent correction
pgfmathtruncatemacroPround(V/S@m*100)
ifthenelseequalC@rrP%
pgfmathparsearray(C@rrP,j)
pgfmathtruncatemacroPP+pgfmathresult
edefPP,%
% current angle and corection
pgfmathtruncatemacroAround(A)
ifthenelseequalC@rrA%
pgfmathparsearray(C@rrA,j)
pgfmathtruncatemacroAA+pgfmathresult
edefAA,degre
% the sector node
ifthenelseequalT@gs%
DiagNode[dc tag]F@ctor T@gs ;
% the legend
ifthenelseequalL@gend%
beginscope[shift=Legend@Loc]
draw[fill=Cj] (0,-.5*j)
rectangle ++(.25,.25) ++(0,-.15)
node[dc legend] strutL@gend ;
endscope
% some more stuff
Sup@Loop ;
% end of diagram code
makeatother
% Node on the j sector
newcommandDiagNode[2][]node[#1] at ($(0,0)!#2!(DCj)$)
begindocument
begintikzpicture
path[%
% style options
dc sector/.append style=shift=(MedA:5pt), % shift all sectors
dc dtag/.append style=,
dc legend/.append style=text width=2cm, align=right,
every pin/.style=fill=Cj,draw=Cj!50!black,thick,
% diagram options
/DiagCirc/.cd,
value list=149/A,1236/R+L+D,740/N+F,346/C,75/E,
angle max=180, % semi-circular
angle corr=0,1,0,0,0, % correct round angle error
legend=N :hfill V, % custom legend
factor=.9,
percent corr=0,-1,0,0,0, % correct round percent error
shift sector=0,0,.3,0,0, % shift individual sector
tags=P, % custom sector nodes
sup loop=% custom features :
%DiagNode1.1 N; % some other sector nodes
% or something else
defPin10,40,150,120,150
pgfmathparsearray(Pin,j)
edefPinjpgfmathresult
node[pin=Pinj:A] at (DCj) ;
,
diagram] ;
endtikzpicture
enddocument
tikz-pgf diagrams charts pgf-pie
There's a nice answer to a pie chart question over here. I tried to bend it to my needs but found some aspects difficult. Specifically:
I'd like to be able to manually adjust the labels.
Rather than adding the degree labels
(newcommanddegre$^circ$
, I assume), I just want to be able
to write something in manually, like a year or date or note or the
variable name for instance.I'd liked to have the option of replacing the percentage labels with
something else too, like the actual value shown in the legend
perhaps.And finally, the numbers aren't formatted nicely. For instance, the
value1236
should ideally be written as1,236
.
Is this kind of customization possible? There are various similar questions about other pie chart designs, but this design is a bit different to most I've seen. Anyway the current code is below.
PS: I kept getting lost in it, so to make reading a bit quicker and easier, I've set:begindocument
through enddocument
in bold, and:value list=149/A,1236/R+L+D,740/N+F,346/C,75/E
in italics, so you can identify it at a glance.
documentclass[margin=5pt]article
usepackage[svgnames]xcolor
usepackagetikz,fourier,ifthen
usetikzlibrarycalc
newcommanddegre$^circ$
colorletcolor0blue!40
colorletcolor1orange!60
colorletcolor2DarkGreen!40
colorletcolor3yellow!60
colorletcolor4red!60
colorletcolor5blue!60!cyan!60
colorletcolor6cyan!60!yellow!60
colorletcolor7red!60!cyan!60
colorletcolor8red!60!blue!60
colorletcolor9orange!60!cyan!60
makeatletter
tikzset%
dc tag/.style=align=center,
dc legend/.style=align=left,anchor=west,
dc sector/.style=fill=Cj,line join=round
pgfkeys/DiagCirc/.cd,
% list of Name/Value
value list/.store in=Value@list,
% circular : 360 - semi circular 180
angle max/.store in=Angle@max,
angle max=360,
% radius of the diagram
radius/.store in=R@dius,
radius=4cm,
% composition of the legend
% V value
% N name
% P percent
% A angle
% Cj color
legend/.store in=L@gend,
legend=,
% location of the legend
legend location/.store in=Legend@Loc,
legend location=($(R@dius,R@dius)+(.5,-.5)$),
% poisition of the node in the sector
% 0 center, 1 on the edge, 1.++ external
factor/.store in=F@ctor,
factor=.80,
% composition of the node in the sector
tags/.store in=T@gs,
tags=,
% correction of round errors in percents
percent corr/.store in=C@rrP,
percent corr=,
% correction of round errors in angles
angle corr/.store in=C@rrA,
angle corr=,
% individual shift
shift sector/.store in=Shift@j,
shift sector=,
% more nodes in the sectors, or new legeng
sup loop/.store in=Sup@Loop,
sup loop=,
% code of the diagram
diagram/.code=%
% Calculation of the sum
pgfmathsetmacroS@m0
foreach i/y in Value@list xdefS@mS@m+i
pgfmathsetmacroS@mS@m
pgfmathsetmacroC@effAngle@max/S@m
% beginning of the first sector
xdef@ngleA0
% main loop
foreach V/N [count=j from 0] in Value@list %
% calculation of the current angle
pgfmathsetmacroAV*C@eff
% superior limit of the sector
pgfmathsetmacro@ngleB@ngleA+A ;
% mean angle
pgfmathsetmacroMedA(@ngleA+@ngleB)/2 ;
% color
pgfmathtruncatemacro@kmod(j,10)
defCjcolor@k
% individual shift
ifthenelseequalShift@j%
edefSh@ft0%
pgfmathparsearray(Shift@j,j)
edefSh@ftpgfmathresult
% drawing of the sector
draw[dc sector,shift=(MedA:Sh@ft)] (0,0)
-- (@ngleA:R@dius) arc (@ngleA:@ngleB:R@dius)
node[midway] (DCj) -- cycle ;
% low limit of the next sector
xdef@ngleA@ngleB ;
% current percent correction
pgfmathtruncatemacroPround(V/S@m*100)
ifthenelseequalC@rrP%
pgfmathparsearray(C@rrP,j)
pgfmathtruncatemacroPP+pgfmathresult
edefPP,%
% current angle and corection
pgfmathtruncatemacroAround(A)
ifthenelseequalC@rrA%
pgfmathparsearray(C@rrA,j)
pgfmathtruncatemacroAA+pgfmathresult
edefAA,degre
% the sector node
ifthenelseequalT@gs%
DiagNode[dc tag]F@ctor T@gs ;
% the legend
ifthenelseequalL@gend%
beginscope[shift=Legend@Loc]
draw[fill=Cj] (0,-.5*j)
rectangle ++(.25,.25) ++(0,-.15)
node[dc legend] strutL@gend ;
endscope
% some more stuff
Sup@Loop ;
% end of diagram code
makeatother
% Node on the j sector
newcommandDiagNode[2][]node[#1] at ($(0,0)!#2!(DCj)$)
begindocument
begintikzpicture
path[%
% style options
dc sector/.append style=shift=(MedA:5pt), % shift all sectors
dc dtag/.append style=,
dc legend/.append style=text width=2cm, align=right,
every pin/.style=fill=Cj,draw=Cj!50!black,thick,
% diagram options
/DiagCirc/.cd,
value list=149/A,1236/R+L+D,740/N+F,346/C,75/E,
angle max=180, % semi-circular
angle corr=0,1,0,0,0, % correct round angle error
legend=N :hfill V, % custom legend
factor=.9,
percent corr=0,-1,0,0,0, % correct round percent error
shift sector=0,0,.3,0,0, % shift individual sector
tags=P, % custom sector nodes
sup loop=% custom features :
%DiagNode1.1 N; % some other sector nodes
% or something else
defPin10,40,150,120,150
pgfmathparsearray(Pin,j)
edefPinjpgfmathresult
node[pin=Pinj:A] at (DCj) ;
,
diagram] ;
endtikzpicture
enddocument
tikz-pgf diagrams charts pgf-pie
tikz-pgf diagrams charts pgf-pie
edited 26 mins ago


Phelype Oleinik
24.9k54690
24.9k54690
asked 29 mins ago


tjt263tjt263
2637
2637
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
PPS: Someone removed thepstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I thinktikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you usepstricks
or whatever, feel free.
– tjt263
12 mins ago
add a comment |
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
PPS: Someone removed thepstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I thinktikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you usepstricks
or whatever, feel free.
– tjt263
12 mins ago
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
PPS: Someone removed the
pstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I think tikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you use pstricks
or whatever, feel free.– tjt263
12 mins ago
PPS: Someone removed the
pstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I think tikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you use pstricks
or whatever, feel free.– tjt263
12 mins ago
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "85"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483940%2fcustomizing-half-pie-chart-labels-with-tikz%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to TeX - LaTeX Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f483940%2fcustomizing-half-pie-chart-labels-with-tikz%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Straight up solutions are welcome, but what would be really nice is if you could also explain a little bit about how it works, so anyone reading can maybe solve similar problems on their/my own in the future. Teach a man to fish and all that. No pressure though, just a suggestion.
– tjt263
21 mins ago
PPS: Someone removed the
pstricks
tag. I used that tag because I also experimented with that package as per the designs on the page I linked to. It seemed simpler, but I still couldn't quite figure it out, despite having some quite nice documentation. I thinktikz
tends to look nicer and I'm a bit familiar with it from drawing other types of charts and diagrams, but if you usepstricks
or whatever, feel free.– tjt263
12 mins ago