Target conversion
Visitors fill a target from the centre out; converters sit in the bull.
Open the chart without page chrome ↗
const options = {
chart: {
height: 420,
fontFamily: "Inter, Geist, \"IBM Plex Sans\", system-ui, sans-serif",
type: "unit",
toolbar: {
show: false
}
},
series: [24, 76, 200],
labels: ["Converted", "Engaged", "Bounced"],
colors: ["#e11d48", "#fb7185", "#e2e8f0"],
plotOptions: {
unit: {
positions: {
name: "target",
category: "generated",
kind: "generated",
rings: [
[
[1, 0.5],
[0.9980973490458728, 0.5435778713738291],
[0.9924038765061041, 0.5868240888334652],
[0.9829629131445341, 0.6294095225512604],
[0.9698463103929542, 0.6710100716628343],
[0.953153893518325, 0.7113091308703497],
[0.9330127018922194, 0.75],
[0.909576022144496, 0.786788218175523],
[0.883022221559489, 0.8213938048432696],
[0.8535533905932737, 0.8535533905932737],
[0.8213938048432696, 0.883022221559489],
[0.786788218175523, 0.909576022144496],
[0.75, 0.9330127018922193],
[0.7113091308703497, 0.953153893518325],
[0.6710100716628344, 0.9698463103929542],
[0.6294095225512604, 0.9829629131445341],
[0.5868240888334653, 0.9924038765061041],
[0.5435778713738292, 0.9980973490458728],
[0.5, 1],
[0.4564221286261709, 0.9980973490458728],
[0.41317591116653485, 0.9924038765061041],
[0.3705904774487396, 0.9829629131445341],
[0.32898992833716567, 0.9698463103929542],
[0.28869086912965036, 0.953153893518325],
[0.2500000000000001, 0.9330127018922194],
[0.2132117818244771, 0.909576022144496],
[0.17860619515673032, 0.883022221559489],
[0.14644660940672627, 0.8535533905932737],
[0.11697777844051105, 0.8213938048432697],
[0.09042397785550405, 0.786788218175523],
[0.06698729810778065, 0.75],
[0.04684610648167503, 0.7113091308703497],
[0.03015368960704584, 0.6710100716628344],
[0.0170370868554659, 0.6294095225512605],
[0.00759612349389599, 0.5868240888334654],
[0.0019026509541272274, 0.5435778713738291],
[0, 0.5000000000000001],
[0.0019026509541272274, 0.45642212862617104],
[0.00759612349389599, 0.41317591116653474],
[0.01703708685546579, 0.37059047744873985],
[0.030153689607045786, 0.32898992833716567],
[0.046846106481674976, 0.28869086912965036],
[0.0669872981077807, 0.24999999999999994],
[0.09042397785550399, 0.2132117818244771],
[0.116977778440511, 0.17860619515673037],
[0.14644660940672616, 0.14644660940672627],
[0.17860619515673026, 0.11697777844051105],
[0.2132117818244768, 0.09042397785550421],
[0.24999999999999978, 0.06698729810778081],
[0.2886908691296504, 0.046846106481674976],
[0.32898992833716534, 0.030153689607045897],
[0.3705904774487397, 0.017037086855465844],
[0.41317591116653485, 0.00759612349389599],
[0.4564221286261709, 0.0019026509541272274],
[0.4999999999999999, 0],
[0.543577871373829, 0.0019026509541272274],
[0.586824088833465, 0.007596123493895934],
[0.6294095225512601, 0.01703708685546579],
[0.6710100716628344, 0.03015368960704584],
[0.7113091308703494, 0.046846106481674865],
[0.75, 0.0669872981077807],
[0.786788218175523, 0.0904239778555041],
[0.8213938048432696, 0.11697777844051094],
[0.8535533905932737, 0.14644660940672616],
[0.883022221559489, 0.1786061951567302],
[0.9095760221444957, 0.21321178182447675],
[0.9330127018922192, 0.24999999999999978],
[0.953153893518325, 0.28869086912965036],
[0.969846310392954, 0.3289899283371653],
[0.9829629131445341, 0.37059047744873963],
[0.9924038765061041, 0.4131759111665348],
[0.9980973490458728, 0.4564221286261708]
],
[
[0.86, 0.5],
[0.8586300913130284, 0.531376067389157],
[0.8545307910843949, 0.5625133439600949],
[0.8477332974640646, 0.5931748562369075],
[0.838289343482927, 0.6231272515972407],
[0.826270803333194, 0.6521425742266518],
[0.8117691453623979, 0.6799999999999999],
[0.794894735944037, 0.7064875170863766],
[0.775775999522832, 0.7314035394871541],
[0.7545584412271571, 0.7545584412271571],
[0.7314035394871542, 0.775775999522832],
[0.7064875170863766, 0.794894735944037],
[0.68, 0.8117691453623979],
[0.6521425742266518, 0.826270803333194],
[0.6231272515972408, 0.838289343482927],
[0.5931748562369075, 0.8477332974640646],
[0.5625133439600949, 0.8545307910843949],
[0.531376067389157, 0.8586300913130284],
[0.5, 0.86],
[0.468623932610843, 0.8586300913130284],
[0.4374866560399051, 0.8545307910843949],
[0.4068251437630925, 0.8477332974640646],
[0.37687274840275925, 0.838289343482927],
[0.3478574257733482, 0.826270803333194],
[0.32000000000000006, 0.8117691453623979],
[0.29351248291362353, 0.794894735944037],
[0.2685964605128458, 0.775775999522832],
[0.2454415587728429, 0.7545584412271571],
[0.22422400047716795, 0.7314035394871542],
[0.2051052640559629, 0.7064875170863765],
[0.18823085463760209, 0.6799999999999999],
[0.17372919666680603, 0.6521425742266518],
[0.161710656517073, 0.6231272515972408],
[0.15226670253593544, 0.5931748562369076],
[0.1454692089156051, 0.562513343960095],
[0.14136990868697163, 0.531376067389157],
[0.14, 0.5],
[0.14136990868697163, 0.4686239326108431],
[0.1454692089156051, 0.43748665603990505],
[0.15226670253593538, 0.40682514376309264],
[0.161710656517073, 0.3768727484027593],
[0.17372919666680597, 0.34785742577334827],
[0.18823085463760214, 0.31999999999999995],
[0.2051052640559629, 0.29351248291362353],
[0.22422400047716795, 0.2685964605128459],
[0.24544155877284285, 0.2454415587728429],
[0.2685964605128458, 0.22422400047716795],
[0.2935124829136233, 0.20510526405596302],
[0.31999999999999984, 0.1882308546376022],
[0.3478574257733483, 0.17372919666680597],
[0.37687274840275903, 0.16171065651707306],
[0.4068251437630926, 0.15226670253593544],
[0.4374866560399051, 0.1454692089156051],
[0.468623932610843, 0.14136990868697163],
[0.49999999999999994, 0.14],
[0.5313760673891569, 0.14136990868697163],
[0.5625133439600948, 0.1454692089156051],
[0.5931748562369072, 0.15226670253593538],
[0.6231272515972408, 0.161710656517073],
[0.6521425742266516, 0.17372919666680592],
[0.68, 0.18823085463760214],
[0.7064875170863766, 0.20510526405596297],
[0.7314035394871541, 0.2242240004771679],
[0.7545584412271571, 0.24544155877284285],
[0.7757759995228319, 0.26859646051284575],
[0.794894735944037, 0.2935124829136233],
[0.8117691453623979, 0.31999999999999984],
[0.826270803333194, 0.3478574257733483],
[0.8382893434829268, 0.37687274840275903],
[0.8477332974640646, 0.40682514376309253],
[0.8545307910843949, 0.43748665603990505],
[0.8586300913130284, 0.468623932610843]
],
[
[0.72, 0.5],
[0.7191628335801841, 0.5191742634044848],
[0.7166577056626857, 0.5382025990867246],
[0.712503681783595, 0.5569401899225546],
[0.7067323765728999, 0.5752444315316472],
[0.699387713148063, 0.5929760175829539],
[0.6905255888325765, 0.61],
[0.6802134497435782, 0.6261868159972301],
[0.6685297774861751, 0.6414132741310387],
[0.6555634918610405, 0.6555634918610405],
[0.6414132741310387, 0.6685297774861751],
[0.6261868159972301, 0.6802134497435782],
[0.61, 0.6905255888325765],
[0.5929760175829539, 0.699387713148063],
[0.5752444315316472, 0.7067323765728999],
[0.5569401899225546, 0.712503681783595],
[0.5382025990867247, 0.7166577056626857],
[0.5191742634044848, 0.7191628335801841],
[0.5, 0.72],
[0.4808257365955152, 0.7191628335801841],
[0.4617974009132753, 0.7166577056626857],
[0.44305981007744544, 0.712503681783595],
[0.4247555684683529, 0.7067323765728999],
[0.4070239824170461, 0.699387713148063],
[0.39000000000000007, 0.6905255888325765],
[0.3738131840027699, 0.6802134497435782],
[0.35858672586896134, 0.6685297774861751],
[0.34443650813895954, 0.6555634918610405],
[0.33147022251382485, 0.6414132741310387],
[0.3197865502564218, 0.6261868159972301],
[0.30947441116742347, 0.61],
[0.30061228685193697, 0.5929760175829539],
[0.29326762342710017, 0.5752444315316472],
[0.287496318216405, 0.5569401899225547],
[0.2833422943373142, 0.5382025990867247],
[0.280837166419816, 0.5191742634044848],
[0.28, 0.5],
[0.280837166419816, 0.48082573659551525],
[0.2833422943373142, 0.4617974009132753],
[0.287496318216405, 0.44305981007744555],
[0.2932676234271001, 0.4247555684683529],
[0.30061228685193697, 0.4070239824170462],
[0.30947441116742347, 0.38999999999999996],
[0.3197865502564218, 0.3738131840027699],
[0.33147022251382485, 0.35858672586896134],
[0.34443650813895954, 0.34443650813895954],
[0.35858672586896134, 0.33147022251382485],
[0.3738131840027698, 0.3197865502564219],
[0.3899999999999999, 0.3094744111674236],
[0.4070239824170462, 0.30061228685193697],
[0.4247555684683527, 0.2932676234271002],
[0.44305981007744544, 0.287496318216405],
[0.4617974009132753, 0.2833422943373142],
[0.4808257365955152, 0.280837166419816],
[0.49999999999999994, 0.28],
[0.5191742634044847, 0.280837166419816],
[0.5382025990867246, 0.28334229433731417],
[0.5569401899225545, 0.287496318216405],
[0.5752444315316472, 0.29326762342710017],
[0.5929760175829537, 0.30061228685193697],
[0.61, 0.30947441116742347],
[0.6261868159972301, 0.3197865502564218],
[0.6414132741310387, 0.33147022251382485],
[0.6555634918610405, 0.34443650813895954],
[0.6685297774861751, 0.3585867258689613],
[0.6802134497435781, 0.37381318400276975],
[0.6905255888325764, 0.3899999999999999],
[0.699387713148063, 0.4070239824170462],
[0.7067323765728998, 0.4247555684683527],
[0.712503681783595, 0.44305981007744544],
[0.7166577056626857, 0.4617974009132753],
[0.7191628335801841, 0.4808257365955152]
]
],
source: "original",
minUnits: 12,
aspect: 1,
order: "centerOut",
cx: undefined,
cy: undefined,
shape: {
name: "target",
category: "generated",
kind: "generated",
minUnits: 12,
order: "centerOut",
source: "original"
},
with: e=>St({...t,...e||{}}),
outlined: function outlined(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.16;const n=t.rings.map(t=>{const n=t.reduce((t,e)=>t+e[0],0)/t.length,a=t.reduce((t,e)=>t+e[1],0)/t.length;return t.map(t=>{let o=b(t,2);return[n+(o[0]-n)*(1-e),a+(o[1]-a)*(1-e)]})});return St({...t,name:t.name+"-outlined",kind:"stroke",rings:t.rings.concat(n)})},
fill: (t,n)=>wt(e,t,n),
isUnitShape: true
}
}
},
title: {
text: "300 visitors, 8% conversion"
},
theme: {
mode: "light",
preset: "coastal"
}
}
const chart = new WestCoastCharts(document.querySelector('#chart'), options)
chart.render()import WestCoastCharts from 'west-coast-charts'
import types from 'west-coast-charts/types'
WestCoastCharts.use(types)
const options = {
chart: {
height: 420,
fontFamily: "Inter, Geist, \"IBM Plex Sans\", system-ui, sans-serif",
type: "unit",
toolbar: {
show: false
}
},
series: [24, 76, 200],
labels: ["Converted", "Engaged", "Bounced"],
colors: ["#e11d48", "#fb7185", "#e2e8f0"],
plotOptions: {
unit: {
positions: {
name: "target",
category: "generated",
kind: "generated",
rings: [
[
[1, 0.5],
[0.9980973490458728, 0.5435778713738291],
[0.9924038765061041, 0.5868240888334652],
[0.9829629131445341, 0.6294095225512604],
[0.9698463103929542, 0.6710100716628343],
[0.953153893518325, 0.7113091308703497],
[0.9330127018922194, 0.75],
[0.909576022144496, 0.786788218175523],
[0.883022221559489, 0.8213938048432696],
[0.8535533905932737, 0.8535533905932737],
[0.8213938048432696, 0.883022221559489],
[0.786788218175523, 0.909576022144496],
[0.75, 0.9330127018922193],
[0.7113091308703497, 0.953153893518325],
[0.6710100716628344, 0.9698463103929542],
[0.6294095225512604, 0.9829629131445341],
[0.5868240888334653, 0.9924038765061041],
[0.5435778713738292, 0.9980973490458728],
[0.5, 1],
[0.4564221286261709, 0.9980973490458728],
[0.41317591116653485, 0.9924038765061041],
[0.3705904774487396, 0.9829629131445341],
[0.32898992833716567, 0.9698463103929542],
[0.28869086912965036, 0.953153893518325],
[0.2500000000000001, 0.9330127018922194],
[0.2132117818244771, 0.909576022144496],
[0.17860619515673032, 0.883022221559489],
[0.14644660940672627, 0.8535533905932737],
[0.11697777844051105, 0.8213938048432697],
[0.09042397785550405, 0.786788218175523],
[0.06698729810778065, 0.75],
[0.04684610648167503, 0.7113091308703497],
[0.03015368960704584, 0.6710100716628344],
[0.0170370868554659, 0.6294095225512605],
[0.00759612349389599, 0.5868240888334654],
[0.0019026509541272274, 0.5435778713738291],
[0, 0.5000000000000001],
[0.0019026509541272274, 0.45642212862617104],
[0.00759612349389599, 0.41317591116653474],
[0.01703708685546579, 0.37059047744873985],
[0.030153689607045786, 0.32898992833716567],
[0.046846106481674976, 0.28869086912965036],
[0.0669872981077807, 0.24999999999999994],
[0.09042397785550399, 0.2132117818244771],
[0.116977778440511, 0.17860619515673037],
[0.14644660940672616, 0.14644660940672627],
[0.17860619515673026, 0.11697777844051105],
[0.2132117818244768, 0.09042397785550421],
[0.24999999999999978, 0.06698729810778081],
[0.2886908691296504, 0.046846106481674976],
[0.32898992833716534, 0.030153689607045897],
[0.3705904774487397, 0.017037086855465844],
[0.41317591116653485, 0.00759612349389599],
[0.4564221286261709, 0.0019026509541272274],
[0.4999999999999999, 0],
[0.543577871373829, 0.0019026509541272274],
[0.586824088833465, 0.007596123493895934],
[0.6294095225512601, 0.01703708685546579],
[0.6710100716628344, 0.03015368960704584],
[0.7113091308703494, 0.046846106481674865],
[0.75, 0.0669872981077807],
[0.786788218175523, 0.0904239778555041],
[0.8213938048432696, 0.11697777844051094],
[0.8535533905932737, 0.14644660940672616],
[0.883022221559489, 0.1786061951567302],
[0.9095760221444957, 0.21321178182447675],
[0.9330127018922192, 0.24999999999999978],
[0.953153893518325, 0.28869086912965036],
[0.969846310392954, 0.3289899283371653],
[0.9829629131445341, 0.37059047744873963],
[0.9924038765061041, 0.4131759111665348],
[0.9980973490458728, 0.4564221286261708]
],
[
[0.86, 0.5],
[0.8586300913130284, 0.531376067389157],
[0.8545307910843949, 0.5625133439600949],
[0.8477332974640646, 0.5931748562369075],
[0.838289343482927, 0.6231272515972407],
[0.826270803333194, 0.6521425742266518],
[0.8117691453623979, 0.6799999999999999],
[0.794894735944037, 0.7064875170863766],
[0.775775999522832, 0.7314035394871541],
[0.7545584412271571, 0.7545584412271571],
[0.7314035394871542, 0.775775999522832],
[0.7064875170863766, 0.794894735944037],
[0.68, 0.8117691453623979],
[0.6521425742266518, 0.826270803333194],
[0.6231272515972408, 0.838289343482927],
[0.5931748562369075, 0.8477332974640646],
[0.5625133439600949, 0.8545307910843949],
[0.531376067389157, 0.8586300913130284],
[0.5, 0.86],
[0.468623932610843, 0.8586300913130284],
[0.4374866560399051, 0.8545307910843949],
[0.4068251437630925, 0.8477332974640646],
[0.37687274840275925, 0.838289343482927],
[0.3478574257733482, 0.826270803333194],
[0.32000000000000006, 0.8117691453623979],
[0.29351248291362353, 0.794894735944037],
[0.2685964605128458, 0.775775999522832],
[0.2454415587728429, 0.7545584412271571],
[0.22422400047716795, 0.7314035394871542],
[0.2051052640559629, 0.7064875170863765],
[0.18823085463760209, 0.6799999999999999],
[0.17372919666680603, 0.6521425742266518],
[0.161710656517073, 0.6231272515972408],
[0.15226670253593544, 0.5931748562369076],
[0.1454692089156051, 0.562513343960095],
[0.14136990868697163, 0.531376067389157],
[0.14, 0.5],
[0.14136990868697163, 0.4686239326108431],
[0.1454692089156051, 0.43748665603990505],
[0.15226670253593538, 0.40682514376309264],
[0.161710656517073, 0.3768727484027593],
[0.17372919666680597, 0.34785742577334827],
[0.18823085463760214, 0.31999999999999995],
[0.2051052640559629, 0.29351248291362353],
[0.22422400047716795, 0.2685964605128459],
[0.24544155877284285, 0.2454415587728429],
[0.2685964605128458, 0.22422400047716795],
[0.2935124829136233, 0.20510526405596302],
[0.31999999999999984, 0.1882308546376022],
[0.3478574257733483, 0.17372919666680597],
[0.37687274840275903, 0.16171065651707306],
[0.4068251437630926, 0.15226670253593544],
[0.4374866560399051, 0.1454692089156051],
[0.468623932610843, 0.14136990868697163],
[0.49999999999999994, 0.14],
[0.5313760673891569, 0.14136990868697163],
[0.5625133439600948, 0.1454692089156051],
[0.5931748562369072, 0.15226670253593538],
[0.6231272515972408, 0.161710656517073],
[0.6521425742266516, 0.17372919666680592],
[0.68, 0.18823085463760214],
[0.7064875170863766, 0.20510526405596297],
[0.7314035394871541, 0.2242240004771679],
[0.7545584412271571, 0.24544155877284285],
[0.7757759995228319, 0.26859646051284575],
[0.794894735944037, 0.2935124829136233],
[0.8117691453623979, 0.31999999999999984],
[0.826270803333194, 0.3478574257733483],
[0.8382893434829268, 0.37687274840275903],
[0.8477332974640646, 0.40682514376309253],
[0.8545307910843949, 0.43748665603990505],
[0.8586300913130284, 0.468623932610843]
],
[
[0.72, 0.5],
[0.7191628335801841, 0.5191742634044848],
[0.7166577056626857, 0.5382025990867246],
[0.712503681783595, 0.5569401899225546],
[0.7067323765728999, 0.5752444315316472],
[0.699387713148063, 0.5929760175829539],
[0.6905255888325765, 0.61],
[0.6802134497435782, 0.6261868159972301],
[0.6685297774861751, 0.6414132741310387],
[0.6555634918610405, 0.6555634918610405],
[0.6414132741310387, 0.6685297774861751],
[0.6261868159972301, 0.6802134497435782],
[0.61, 0.6905255888325765],
[0.5929760175829539, 0.699387713148063],
[0.5752444315316472, 0.7067323765728999],
[0.5569401899225546, 0.712503681783595],
[0.5382025990867247, 0.7166577056626857],
[0.5191742634044848, 0.7191628335801841],
[0.5, 0.72],
[0.4808257365955152, 0.7191628335801841],
[0.4617974009132753, 0.7166577056626857],
[0.44305981007744544, 0.712503681783595],
[0.4247555684683529, 0.7067323765728999],
[0.4070239824170461, 0.699387713148063],
[0.39000000000000007, 0.6905255888325765],
[0.3738131840027699, 0.6802134497435782],
[0.35858672586896134, 0.6685297774861751],
[0.34443650813895954, 0.6555634918610405],
[0.33147022251382485, 0.6414132741310387],
[0.3197865502564218, 0.6261868159972301],
[0.30947441116742347, 0.61],
[0.30061228685193697, 0.5929760175829539],
[0.29326762342710017, 0.5752444315316472],
[0.287496318216405, 0.5569401899225547],
[0.2833422943373142, 0.5382025990867247],
[0.280837166419816, 0.5191742634044848],
[0.28, 0.5],
[0.280837166419816, 0.48082573659551525],
[0.2833422943373142, 0.4617974009132753],
[0.287496318216405, 0.44305981007744555],
[0.2932676234271001, 0.4247555684683529],
[0.30061228685193697, 0.4070239824170462],
[0.30947441116742347, 0.38999999999999996],
[0.3197865502564218, 0.3738131840027699],
[0.33147022251382485, 0.35858672586896134],
[0.34443650813895954, 0.34443650813895954],
[0.35858672586896134, 0.33147022251382485],
[0.3738131840027698, 0.3197865502564219],
[0.3899999999999999, 0.3094744111674236],
[0.4070239824170462, 0.30061228685193697],
[0.4247555684683527, 0.2932676234271002],
[0.44305981007744544, 0.287496318216405],
[0.4617974009132753, 0.2833422943373142],
[0.4808257365955152, 0.280837166419816],
[0.49999999999999994, 0.28],
[0.5191742634044847, 0.280837166419816],
[0.5382025990867246, 0.28334229433731417],
[0.5569401899225545, 0.287496318216405],
[0.5752444315316472, 0.29326762342710017],
[0.5929760175829537, 0.30061228685193697],
[0.61, 0.30947441116742347],
[0.6261868159972301, 0.3197865502564218],
[0.6414132741310387, 0.33147022251382485],
[0.6555634918610405, 0.34443650813895954],
[0.6685297774861751, 0.3585867258689613],
[0.6802134497435781, 0.37381318400276975],
[0.6905255888325764, 0.3899999999999999],
[0.699387713148063, 0.4070239824170462],
[0.7067323765728998, 0.4247555684683527],
[0.712503681783595, 0.44305981007744544],
[0.7166577056626857, 0.4617974009132753],
[0.7191628335801841, 0.4808257365955152]
]
],
source: "original",
minUnits: 12,
aspect: 1,
order: "centerOut",
cx: undefined,
cy: undefined,
shape: {
name: "target",
category: "generated",
kind: "generated",
minUnits: 12,
order: "centerOut",
source: "original"
},
with: e=>St({...t,...e||{}}),
outlined: function outlined(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.16;const n=t.rings.map(t=>{const n=t.reduce((t,e)=>t+e[0],0)/t.length,a=t.reduce((t,e)=>t+e[1],0)/t.length;return t.map(t=>{let o=b(t,2);return[n+(o[0]-n)*(1-e),a+(o[1]-a)*(1-e)]})});return St({...t,name:t.name+"-outlined",kind:"stroke",rings:t.rings.concat(n)})},
fill: (t,n)=>wt(e,t,n),
isUnitShape: true
}
}
},
title: {
text: "300 visitors, 8% conversion"
},
theme: {
mode: "light",
preset: "coastal"
}
}
const chart = new WestCoastCharts(document.querySelector('#chart'), options)
await chart.render() Waiting for the chart.
Open Data & agent view to read this chart through chart.describe().
Read from the running library through its optional agent/describe module. Text, table and JSON share the same snapshot. Demo data only.
$ wcc chart export unit-target-conversion.json --out unit-target-conversion.svg --with-table Public agent tools 0.2.3, tested with Library 1.1.5; available from the versioned GitHub release and npm. Save a JSON spec first and check the loaded runtime and supported modules before rendering. Command reference
Loading /gallery/unit/target-conversion/index.md …