prographs 0.12.0 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -1
- package/README.md +6 -4
- package/dist/AutoGraph-PDPEAIXL.cjs +145 -0
- package/dist/GraphType.js +19 -0
- package/dist/autograph/chartIndex.js +521 -0
- package/dist/autograph/chartModules.js +2 -1
- package/dist/autograph/index.cjs +98 -93
- package/dist/catalog-DI4XZ46L.cjs +142 -0
- package/dist/catalog.js +2 -1
- package/dist/charts/biologycharts/BiologySamples.js +59 -0
- package/dist/charts/biologycharts/PunnettSquare.js +342 -0
- package/dist/charts/biologycharts/biologyEnums.js +22 -1
- package/dist/charts/biologycharts/index.js +5 -3
- package/dist/charts/doecharts/DoeSamples.js +78 -0
- package/dist/charts/doecharts/SipocDiagram.js +453 -0
- package/dist/charts/doecharts/index.js +4 -2
- package/dist/charts/fieldcharts/SpeciesAccumulationCurve.js +350 -0
- package/dist/charts/fieldcharts/fieldEnums.js +8 -1
- package/dist/charts/fieldcharts/index.js +5 -3
- package/dist/charts/signals/AntennaPatternChart.js +492 -0
- package/dist/charts/signals/SignalSamples.js +17 -0
- package/dist/charts/signals/index.js +5 -3
- package/dist/charts/softwarediagrams/ComponentDiagram.js +504 -0
- package/dist/charts/softwarediagrams/DeploymentDiagram.js +419 -0
- package/dist/charts/softwarediagrams/SoftwareSamples.js +283 -1
- package/dist/charts/softwarediagrams/index.js +7 -3
- package/dist/charts/softwarediagrams/softwareEnums.js +45 -1
- package/dist/charts/sportscharts/PowerDurationCurve.js +301 -0
- package/dist/charts/sportscharts/SportsSamples.js +102 -0
- package/dist/charts/sportscharts/TrainingLoadChart.js +325 -0
- package/dist/charts/sportscharts/index.js +6 -2
- package/dist/charts/strategycharts/BassDiffusionChart.js +362 -0
- package/dist/charts/strategycharts/BassModel.js +96 -0
- package/dist/charts/strategycharts/BurnRunwayChart.js +284 -0
- package/dist/charts/strategycharts/CapTableChart.js +366 -0
- package/dist/charts/strategycharts/KanbanBoard.js +324 -0
- package/dist/charts/strategycharts/OkrTree.js +339 -0
- package/dist/charts/strategycharts/StrategyPane.js +27 -0
- package/dist/charts/strategycharts/StrategySamples.js +251 -0
- package/dist/charts/strategycharts/index.js +15 -3
- package/dist/charts/threefields/BsfcMap3DChart.js +231 -0
- package/dist/charts/threefields/CompressorMap3DChart.js +217 -0
- package/dist/charts/threefields/FieldGrid.js +50 -0
- package/dist/charts/threefields/LossLandscape3DChart.js +201 -0
- package/dist/charts/threefields/MapSheet.js +77 -0
- package/dist/charts/threefields/TerrainRoute3DChart.js +201 -0
- package/dist/charts/threefields/TerrainRouteMath.js +40 -0
- package/dist/charts/threefields/ThreeFieldBase.js +117 -0
- package/dist/charts/threefields/ThreeFieldsSamples.js +80 -0
- package/dist/charts/threefields/WaferMap3DChart.js +218 -0
- package/dist/charts/threefields/index.js +19 -0
- package/dist/charts/threesurfaces/index.js +2 -2
- package/dist/charts/tradingcharts/KeltnerChannelChart.js +171 -0
- package/dist/charts/tradingcharts/TradingMath.js +20 -0
- package/dist/charts/tradingcharts/index.js +4 -2
- package/dist/{chunk-ZL6XDXMK.cjs → chunk-26PSLEP4.cjs} +8 -8
- package/dist/{chunk-W3US6EFP.cjs → chunk-2BO5DZUP.cjs} +12 -12
- package/dist/{chunk-5DP7OUSE.cjs → chunk-2GG5YYSC.cjs} +6 -6
- package/dist/{chunk-7FG4JSVO.cjs → chunk-2GL2VNJU.cjs} +253 -33
- package/dist/{chunk-LCWMRCLF.cjs → chunk-2PYOI7OY.cjs} +21 -21
- package/dist/{chunk-JFWJAEBD.cjs → chunk-3U4MCSKI.cjs} +4 -4
- package/dist/{chunk-CUPLHZRR.cjs → chunk-3ZMM3FSK.cjs} +4 -4
- package/dist/{chunk-L2AV62DP.cjs → chunk-4767WQJ7.cjs} +6 -6
- package/dist/{chunk-DA2EYIIP.cjs → chunk-4E7FSSBF.cjs} +1210 -168
- package/dist/{chunk-VS5LQEZB.cjs → chunk-526STI2S.cjs} +5 -5
- package/dist/{chunk-RXIMEK6C.cjs → chunk-55767YPI.cjs} +20 -20
- package/dist/{chunk-JXLSKIUV.cjs → chunk-5FBQOMMT.cjs} +26 -26
- package/dist/{chunk-27PZV5BR.cjs → chunk-5N4Z7MTS.cjs} +4 -4
- package/dist/{chunk-KEWCUIQA.cjs → chunk-5WEV6YWA.cjs} +22 -22
- package/dist/chunk-5XOVVC5X.cjs +3281 -0
- package/dist/{chunk-HK5J7Q2W.cjs → chunk-6HLXVWXU.cjs} +9 -9
- package/dist/{chunk-7JG47RW4.cjs → chunk-6LQT4WJ5.cjs} +25 -25
- package/dist/{chunk-OCVTI6X4.cjs → chunk-6YTWOUFD.cjs} +329 -36
- package/dist/{chunk-W7IQCAVN.cjs → chunk-7F6W6HKL.cjs} +11 -11
- package/dist/{chunk-F2DCJXDM.cjs → chunk-7L6KYU5A.cjs} +21 -21
- package/dist/{chunk-GTGR6LPR.cjs → chunk-A4GIN4FE.cjs} +17 -17
- package/dist/{chunk-B2CETSR6.cjs → chunk-A4US7SA7.cjs} +5 -5
- package/dist/{chunk-3DIF2YYW.cjs → chunk-AOXPBLPW.cjs} +10 -10
- package/dist/{chunk-7TTR4UF5.cjs → chunk-ATI45Z4M.cjs} +2 -2
- package/dist/{chunk-5BFCIX2V.cjs → chunk-CPPMO4IQ.cjs} +434 -148
- package/dist/{chunk-AYZZQ6AC.cjs → chunk-CZ5KGF6Q.cjs} +9 -9
- package/dist/{chunk-7THJ3ZBK.cjs → chunk-D4I35MCE.cjs} +2 -2
- package/dist/{chunk-MCPPFRLN.cjs → chunk-DCGAAN3Z.cjs} +2 -2
- package/dist/{chunk-VABL6CVX.cjs → chunk-DEY36N37.cjs} +21 -21
- package/dist/{chunk-RNCKGJCC.cjs → chunk-DXHXD3DK.cjs} +3 -3
- package/dist/{chunk-A56ZGMVZ.cjs → chunk-E7B45DBZ.cjs} +11 -11
- package/dist/{chunk-DOR6L4MT.cjs → chunk-EJC6EAC5.cjs} +18 -18
- package/dist/{chunk-UPGNM7MA.cjs → chunk-EULJOOMA.cjs} +11 -11
- package/dist/{chunk-G4AZL4GO.cjs → chunk-EYM6LEIF.cjs} +474 -70
- package/dist/{chunk-NJ4X6XGV.cjs → chunk-EZTYX2GH.cjs} +5 -5
- package/dist/chunk-FDD4UP73.cjs +521 -0
- package/dist/{chunk-WJ3VH2Q4.cjs → chunk-GEAIGM3J.cjs} +110 -615
- package/dist/{chunk-P3SBHF43.cjs → chunk-GRUYVXTS.cjs} +2 -2
- package/dist/{chunk-NX4Z5LMS.cjs → chunk-H3SZXND5.cjs} +5 -5
- package/dist/{chunk-EE4S4TOE.cjs → chunk-HS45TOFJ.cjs} +21 -21
- package/dist/chunk-INGOG6OV.cjs +899 -0
- package/dist/{chunk-UDKA6DGT.cjs → chunk-J3CDXZHF.cjs} +4 -4
- package/dist/{chunk-YO6G7TKI.cjs → chunk-JAU5ADEU.cjs} +11 -11
- package/dist/{chunk-22LBK4GA.cjs → chunk-JQEBSHX3.cjs} +4 -4
- package/dist/{chunk-RXX3U7VQ.cjs → chunk-KLXGLMFU.cjs} +10 -10
- package/dist/chunk-KVOX36J3.cjs +327 -0
- package/dist/chunk-L6BGNHFL.cjs +139 -0
- package/dist/{chunk-GMER35L3.cjs → chunk-L7TB7PU5.cjs} +20 -20
- package/dist/{chunk-AFXYNBL2.cjs → chunk-LBTRYEM2.cjs} +4 -4
- package/dist/{chunk-WYYCKIOD.cjs → chunk-LLULNJSP.cjs} +11 -11
- package/dist/{chunk-J27XOSLP.cjs → chunk-LSO46AFV.cjs} +8 -8
- package/dist/{chunk-5XJO45ES.cjs → chunk-LZ2KJ7ZX.cjs} +11 -11
- package/dist/chunk-M4IQ5LIZ.cjs +422 -0
- package/dist/{chunk-Y2KIUKJF.cjs → chunk-MPDHDKYZ.cjs} +11 -11
- package/dist/{chunk-4EMPKRZU.cjs → chunk-MRQ42ZJE.cjs} +3 -3
- package/dist/{chunk-EU5D2MF4.cjs → chunk-MYV4KZWP.cjs} +9 -9
- package/dist/{chunk-XD7KN4UN.cjs → chunk-MZXVLC24.cjs} +6 -6
- package/dist/{chunk-PPSONARU.cjs → chunk-NLBVDFIR.cjs} +41 -2
- package/dist/{chunk-L3PEGMGM.cjs → chunk-NY3TBZY4.cjs} +33 -33
- package/dist/{chunk-6YNYXXB6.cjs → chunk-OGVVSFAR.cjs} +3 -3
- package/dist/{chunk-MLV7QLB6.cjs → chunk-OMTQIQMN.cjs} +6 -6
- package/dist/{chunk-BEEOSNK7.cjs → chunk-PEJJ6TXJ.cjs} +15 -144
- package/dist/{chunk-SOKOWUF5.cjs → chunk-PPGWHIU7.cjs} +2 -2
- package/dist/{chunk-IELWOM2J.cjs → chunk-PPO6SDAN.cjs} +6 -6
- package/dist/{chunk-6JTZZCSL.cjs → chunk-PUMKX5F2.cjs} +3 -3
- package/dist/{chunk-RFOXFY2U.cjs → chunk-PXBYWCNB.cjs} +190 -799
- package/dist/{chunk-3BYXOISI.cjs → chunk-Q3HB3IX6.cjs} +4 -4
- package/dist/{chunk-RXCOVONX.cjs → chunk-RBMUOIXE.cjs} +289 -34
- package/dist/{chunk-MSBNHCSE.cjs → chunk-RJHGCUUD.cjs} +6 -6
- package/dist/{chunk-I6VG7F6Z.cjs → chunk-RSONDMYW.cjs} +708 -141
- package/dist/{chunk-GZDNPHMT.cjs → chunk-SHMPFCUE.cjs} +19 -19
- package/dist/{chunk-ZIBVCOW6.cjs → chunk-SN4FCXFC.cjs} +19 -19
- package/dist/{chunk-7KM52NMN.cjs → chunk-SN5T7WYO.cjs} +2 -2
- package/dist/{chunk-7MSZR65Z.cjs → chunk-SQJZGVDR.cjs} +7 -7
- package/dist/chunk-SYABFMD7.cjs +633 -0
- package/dist/{chunk-2RRFEYFH.cjs → chunk-TICB3MAC.cjs} +16 -16
- package/dist/{chunk-AOOKHUV5.cjs → chunk-U7Z7XYR2.cjs} +5 -5
- package/dist/{chunk-JEWQAXVG.cjs → chunk-UA2THQFV.cjs} +6 -6
- package/dist/{chunk-LHZPAHU3.cjs → chunk-VIK4L2YF.cjs} +112 -521
- package/dist/{chunk-4YWMAQ4J.cjs → chunk-VM2Y6BDY.cjs} +4 -4
- package/dist/{chunk-IRRKE2ZE.cjs → chunk-VMS3KWYI.cjs} +21 -21
- package/dist/{chunk-4SLARW6F.cjs → chunk-VU5NUD46.cjs} +17 -17
- package/dist/{chunk-XHY6TVYG.cjs → chunk-VV5CVOF7.cjs} +13 -13
- package/dist/{chunk-CCIBPGPZ.cjs → chunk-VYSAWPSS.cjs} +57 -57
- package/dist/{chunk-TTNEMQ2A.cjs → chunk-W7YRWEWQ.cjs} +22 -22
- package/dist/{chunk-C7MUOGEW.cjs → chunk-X7R5SY62.cjs} +6 -6
- package/dist/{chunk-ILR5KBMB.cjs → chunk-XOK3KTSS.cjs} +6 -6
- package/dist/{chunk-2CZM2I3T.cjs → chunk-XUIX45VU.cjs} +19 -19
- package/dist/{chunk-TGRMPS3A.cjs → chunk-XWH46PVJ.cjs} +165 -43
- package/dist/{chunk-WQYXXECR.cjs → chunk-Y5XVMK3K.cjs} +6 -6
- package/dist/{chunk-AK4TX2WG.cjs → chunk-YCNKEDTG.cjs} +13 -13
- package/dist/{chunk-PJJB24DU.cjs → chunk-YEF7SE3X.cjs} +20 -20
- package/dist/{chunk-RVLV4XW6.cjs → chunk-YMTVPMU3.cjs} +22 -22
- package/dist/data/index.cjs +2 -2
- package/dist/entries/autograph-lazy.cjs +2 -2
- package/dist/entries/charts/acoustictransport.cjs +3 -3
- package/dist/entries/charts/analysischarts.cjs +3 -3
- package/dist/entries/charts/astrocharts.cjs +3 -3
- package/dist/entries/charts/bars.cjs +3 -3
- package/dist/entries/charts/bayesiancharts.cjs +3 -3
- package/dist/entries/charts/biocharts.cjs +3 -3
- package/dist/entries/charts/biologycharts.cjs +11 -3
- package/dist/entries/charts/biologycharts.d.ts +1 -1
- package/dist/entries/charts/biologycharts.js +3 -2
- package/dist/entries/charts/business.cjs +3 -3
- package/dist/entries/charts/carecharts.cjs +3 -3
- package/dist/entries/charts/chemistrycharts.cjs +3 -3
- package/dist/entries/charts/civicscharts.cjs +3 -3
- package/dist/entries/charts/clinicalcharts.cjs +3 -3
- package/dist/entries/charts/comparison.cjs +3 -3
- package/dist/entries/charts/demography.cjs +3 -3
- package/dist/entries/charts/density.cjs +3 -3
- package/dist/entries/charts/diagrams.cjs +3 -3
- package/dist/entries/charts/distribution.cjs +3 -3
- package/dist/entries/charts/doecharts.cjs +13 -3
- package/dist/entries/charts/doecharts.d.ts +1 -1
- package/dist/entries/charts/doecharts.js +2 -1
- package/dist/entries/charts/earthscience.cjs +3 -3
- package/dist/entries/charts/economicscharts.cjs +3 -3
- package/dist/entries/charts/energycharts.cjs +3 -3
- package/dist/entries/charts/engineering.cjs +3 -3
- package/dist/entries/charts/fieldcharts.cjs +7 -3
- package/dist/entries/charts/fieldcharts.d.ts +1 -1
- package/dist/entries/charts/fieldcharts.js +3 -2
- package/dist/entries/charts/financial.cjs +3 -3
- package/dist/entries/charts/flow.cjs +3 -3
- package/dist/entries/charts/frameworks.cjs +3 -3
- package/dist/entries/charts/genomics.cjs +3 -3
- package/dist/entries/charts/geoflows.cjs +3 -3
- package/dist/entries/charts/geomaps.cjs +3 -3
- package/dist/entries/charts/geosciencecharts.cjs +3 -3
- package/dist/entries/charts/hierarchy.cjs +3 -3
- package/dist/entries/charts/indicators.cjs +3 -3
- package/dist/entries/charts/inferencecharts.cjs +3 -3
- package/dist/entries/charts/layoutcharts.cjs +3 -3
- package/dist/entries/charts/lifescience.cjs +4 -4
- package/dist/entries/charts/linesareas.cjs +3 -3
- package/dist/entries/charts/logisticscharts.cjs +3 -3
- package/dist/entries/charts/machinecharts.cjs +7 -3
- package/dist/entries/charts/machinecharts.d.ts +1 -1
- package/dist/entries/charts/machinecharts.js +2 -1
- package/dist/entries/charts/massive.cjs +3 -3
- package/dist/entries/charts/mathematical.cjs +3 -3
- package/dist/entries/charts/matrix.cjs +3 -3
- package/dist/entries/charts/medicalcharts.cjs +4 -4
- package/dist/entries/charts/mlcharts.cjs +4 -4
- package/dist/entries/charts/modelcharts.cjs +6 -5
- package/dist/entries/charts/multivariate.cjs +3 -3
- package/dist/entries/charts/musiccharts.cjs +3 -3
- package/dist/entries/charts/network.cjs +3 -3
- package/dist/entries/charts/physicscharts.cjs +3 -3
- package/dist/entries/charts/pictorial.cjs +4 -4
- package/dist/entries/charts/portfoliocharts.cjs +3 -3
- package/dist/entries/charts/productcharts.cjs +3 -3
- package/dist/entries/charts/proportion.cjs +3 -3
- package/dist/entries/charts/qualitycharts.cjs +3 -3
- package/dist/entries/charts/radial.cjs +3 -3
- package/dist/entries/charts/reliabilitycharts.cjs +5 -3
- package/dist/entries/charts/scatter.cjs +3 -3
- package/dist/entries/charts/scientific.cjs +3 -3
- package/dist/entries/charts/seriescharts.cjs +3 -3
- package/dist/entries/charts/signals.cjs +7 -3
- package/dist/entries/charts/signals.d.ts +1 -1
- package/dist/entries/charts/signals.js +2 -1
- package/dist/entries/charts/softwarediagrams.cjs +21 -3
- package/dist/entries/charts/softwarediagrams.d.ts +1 -1
- package/dist/entries/charts/softwarediagrams.js +4 -2
- package/dist/entries/charts/sportscharts.cjs +13 -3
- package/dist/entries/charts/sportscharts.d.ts +1 -1
- package/dist/entries/charts/sportscharts.js +3 -1
- package/dist/entries/charts/statistics.cjs +6 -6
- package/dist/entries/charts/strategycharts.cjs +30 -3
- package/dist/entries/charts/strategycharts.d.ts +1 -1
- package/dist/entries/charts/strategycharts.js +6 -1
- package/dist/entries/charts/structure.cjs +3 -3
- package/dist/entries/charts/surveycharts.cjs +3 -3
- package/dist/entries/charts/systemscharts.cjs +3 -3
- package/dist/entries/charts/textcharts.cjs +5 -5
- package/dist/entries/charts/thematicmaps.cjs +4 -4
- package/dist/entries/charts/threebars.cjs +3 -3
- package/dist/entries/charts/threefields.cjs +53 -0
- package/dist/entries/charts/threefields.d.ts +1 -0
- package/dist/entries/charts/threefields.js +6 -0
- package/dist/entries/charts/threeglobe.cjs +3 -3
- package/dist/entries/charts/threenetwork.cjs +3 -3
- package/dist/entries/charts/threestrata.cjs +3 -3
- package/dist/entries/charts/threesurfaces.cjs +7 -3
- package/dist/entries/charts/threesurfaces.d.ts +1 -1
- package/dist/entries/charts/threesurfaces.js +2 -1
- package/dist/entries/charts/threevolume.cjs +4 -4
- package/dist/entries/charts/timeline.cjs +3 -3
- package/dist/entries/charts/tracecharts.cjs +3 -3
- package/dist/entries/charts/trackscharts.cjs +3 -3
- package/dist/entries/charts/tradingcharts.cjs +6 -4
- package/dist/entries/charts/tradingcharts.d.ts +1 -1
- package/dist/entries/charts/tradingcharts.js +2 -1
- package/dist/entries/three.cjs +60 -20
- package/dist/entries/three.d.ts +1 -1
- package/dist/entries/three.js +7 -1
- package/dist/index.cjs +258 -97
- package/dist/index.d.cts +1953 -10
- package/dist/index.d.ts +1953 -10
- package/dist/index.js +26 -5
- package/dist/page/index.cjs +2 -2
- package/dist/react/components.js +58 -1
- package/dist/react/index.cjs +135 -92
- package/dist/react/index.d.ts +1 -1
- package/dist/react/index.js +2 -2
- package/package.json +1 -1
- package/dist/AutoGraph-XLBJQDRB.cjs +0 -140
- package/dist/catalog-O7XGDD2H.cjs +0 -137
- package/dist/chunk-77K2HTRC.cjs +0 -3220
- package/dist/chunk-XEK47TVD.cjs +0 -323
- /package/dist/{chunk-UMEKIIHJ.cjs → chunk-LNWTC72Y.cjs} +0 -0
|
@@ -6,7 +6,7 @@ var _chunkEEF5WRRZcjs = require('./chunk-EEF5WRRZ.cjs');
|
|
|
6
6
|
var _chunkPY4R3IFFcjs = require('./chunk-PY4R3IFF.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
10
10
|
|
|
11
11
|
// src/charts/indicators/IndicatorEnums.ts
|
|
12
12
|
var GaugeSweep = /* @__PURE__ */ ((GaugeSweep2) => {
|
|
@@ -555,7 +555,7 @@ var ActivityRings = (_class = class extends IndicatorChart {
|
|
|
555
555
|
shape: "table" /* Table */,
|
|
556
556
|
description: "Tracks a few daily goals as concentric rings that close at 100% and lap when a goal is exceeded.",
|
|
557
557
|
tags: ["fitness", "rings", "goals", "streak"],
|
|
558
|
-
sample: (seed) =>
|
|
558
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 4, 3).map((row) => ({ ...row, target: 60 })),
|
|
559
559
|
variants: {
|
|
560
560
|
history: [false, true],
|
|
561
561
|
overflow: ["wrap" /* Wrap */, "clamp" /* Clamp */],
|
|
@@ -639,7 +639,7 @@ var ActivityRings = (_class = class extends IndicatorChart {
|
|
|
639
639
|
var IndicatorSamples = class {
|
|
640
640
|
/** `{ category, value, target, previous }`, one row per category. */
|
|
641
641
|
static goals(seed, count) {
|
|
642
|
-
return
|
|
642
|
+
return _chunkLNWTC72Ycjs.SampleData.categories(seed, count, 3).reduce((rows, row, i, all) => {
|
|
643
643
|
if (i % 3 === 0) rows.push({ category: row.category, value: row.value, target: Math.round(+all[i + 1].value * 0.4 + 52), previous: all[i + 2].value });
|
|
644
644
|
return rows;
|
|
645
645
|
}, []);
|
|
@@ -1146,7 +1146,7 @@ var HarveyBalls = (_class6 = class extends IndicatorChart {
|
|
|
1146
1146
|
shape: "table" /* Table */,
|
|
1147
1147
|
description: "Scores options against criteria with part-filled circles, for comparison tables and capability grids.",
|
|
1148
1148
|
tags: ["qualitative", "comparison table", "capability", "maturity"],
|
|
1149
|
-
sample: (seed) =>
|
|
1149
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 5, 4),
|
|
1150
1150
|
variants: {
|
|
1151
1151
|
layout: ["matrix" /* Matrix */, "list" /* List */],
|
|
1152
1152
|
form: ["pie" /* Pie */, "level" /* Level */, "ring" /* Ring */],
|
|
@@ -1242,7 +1242,7 @@ var KpiTile = (_class7 = class extends IndicatorChart {
|
|
|
1242
1242
|
shape: "table" /* Table */,
|
|
1243
1243
|
description: "A stat tile pairing the latest value with its change and a sparkline of recent history.",
|
|
1244
1244
|
tags: ["stat", "sparkline", "delta", "dashboard", "big number"],
|
|
1245
|
-
sample: (seed) =>
|
|
1245
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.timeSeries(seed, 30, 2),
|
|
1246
1246
|
variants: {
|
|
1247
1247
|
layout: ["stacked" /* Stacked */, "split" /* Split */, "backdrop" /* Backdrop */],
|
|
1248
1248
|
spark: ["line" /* Line */, "area" /* Area */, "bars" /* Bars */, "step" /* Step */, "no-spark" /* None */],
|
|
@@ -1790,7 +1790,7 @@ var RatingStars = (_class12 = class extends IndicatorChart {constructor(...args2
|
|
|
1790
1790
|
shape: "table" /* Table */,
|
|
1791
1791
|
description: "Shows review scores as partly filled symbols, as a list, a headline average or a breakdown by score.",
|
|
1792
1792
|
tags: ["reviews", "score", "stars", "feedback"],
|
|
1793
|
-
sample: (seed) =>
|
|
1793
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 6, 3).map((row) => ({ ...row, value: +(+row.value / 20).toFixed(1) })),
|
|
1794
1794
|
variants: {
|
|
1795
1795
|
layout: ["list" /* List */, "hero" /* Hero */, "breakdown" /* Breakdown */],
|
|
1796
1796
|
glyph: ["star" /* Star */, "heart" /* Heart */, "circle" /* Circle */, "diamond" /* Diamond */],
|
|
@@ -2156,7 +2156,7 @@ var StepProgress = (_class16 = class extends IndicatorChart {
|
|
|
2156
2156
|
description: "Shows which stage of an ordered process is complete, in progress or still to come.",
|
|
2157
2157
|
tags: ["stepper", "stages", "pipeline", "wizard"],
|
|
2158
2158
|
sample: (seed) => {
|
|
2159
|
-
const tasks =
|
|
2159
|
+
const tasks = _chunkLNWTC72Ycjs.SampleData.tasks(seed, 6), reached = Math.round(+tasks[0].progress * 3) + 1;
|
|
2160
2160
|
return tasks.map((task, i) => ({ category: `Stage ${i + 1}`, value: i < reached ? 100 : i === reached ? Math.round(+task.progress * 80) + 10 : 0 }));
|
|
2161
2161
|
},
|
|
2162
2162
|
variants: {
|
|
@@ -2264,7 +2264,7 @@ var TallyChart = (_class17 = class extends IndicatorChart {
|
|
|
2264
2264
|
shape: "table" /* Table */,
|
|
2265
2265
|
description: "Records counts as groups of five tally marks, so totals can be read by bundles at a glance.",
|
|
2266
2266
|
tags: ["count", "hash marks", "frequency", "classroom"],
|
|
2267
|
-
sample: (seed) =>
|
|
2267
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 5, 1).map((row) => ({ ...row, value: Math.round(+row.value / 3) })),
|
|
2268
2268
|
variants: {
|
|
2269
2269
|
bundle: ["gate" /* Gate */, "zheng" /* Zheng */, "box" /* Box */, "plain" /* Plain */],
|
|
2270
2270
|
layout: ["rows" /* Rows */, "columns" /* Columns */],
|
|
@@ -2518,7 +2518,7 @@ var TrafficLightChart = (_class20 = class extends IndicatorChart {
|
|
|
2518
2518
|
shape: "table" /* Table */,
|
|
2519
2519
|
description: "Shows the red, amber or green state of each item, each lamp named so status never rests on colour alone.",
|
|
2520
2520
|
tags: ["rag", "status", "red amber green", "health"],
|
|
2521
|
-
sample: (seed) =>
|
|
2521
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 5, 3).map((row) => ({ ...row, value: Math.round(+row.value * 0.9) })),
|
|
2522
2522
|
variants: {
|
|
2523
2523
|
layout: ["housing" /* Housing */, "list" /* List */, "matrix" /* Matrix */],
|
|
2524
2524
|
orientation: ["vertical" /* Vertical */, "horizontal" /* Horizontal */],
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
4
4
|
|
|
5
5
|
// src/charts/pictorial/Corpus.ts
|
|
6
6
|
var _d3 = require('d3');
|
|
@@ -31,7 +31,7 @@ var Corpus = class {
|
|
|
31
31
|
}
|
|
32
32
|
/** `{ text, value }` sentences reshaped from `SampleData.words`, heavy words recurring as they would in prose. */
|
|
33
33
|
static sample(seed, count = 64) {
|
|
34
|
-
const words =
|
|
34
|
+
const words = _chunkLNWTC72Ycjs.SampleData.words(seed).sort((a, b) => +b.value - +a.value).slice(0, 12).map((word) => String(word.text));
|
|
35
35
|
const random = _d3.randomLcg.call(void 0, seed * 0.37 % 1);
|
|
36
36
|
const pick = () => words[Math.floor(random() ** 2 * words.length)];
|
|
37
37
|
return Array.from({ length: count }, () => {
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
var _chunkUXFWDEP6cjs = require('./chunk-UXFWDEP6.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
7
7
|
|
|
8
8
|
// src/charts/statistics/ClassifierCurveBase.ts
|
|
9
9
|
var _d3 = require('d3');
|
|
10
10
|
var ClassifierCurveBase = class extends _chunkUXFWDEP6cjs.StatisticalChart {
|
|
11
11
|
/** Three models of rising skill over the same 30% prevalence. */
|
|
12
12
|
static scored(seed) {
|
|
13
|
-
const rows =
|
|
13
|
+
const rows = _chunkLNWTC72Ycjs.SampleData.distribution(seed, 140, 4);
|
|
14
14
|
const of = (name) => rows.filter((row) => row.group === name).map((row) => +row.value);
|
|
15
15
|
const probability = (value) => +(1 / (1 + Math.exp(-(value - 54) / 6))).toFixed(4);
|
|
16
16
|
return [["Boosted", "Delta"], ["Logistic", "Charlie"], ["Baseline", "Bravo"]].flatMap(([model, positive]) => [
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunk55767YPIcjs = require('./chunk-55767YPI.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -14,7 +14,7 @@ var _chunkEEF5WRRZcjs = require('./chunk-EEF5WRRZ.cjs');
|
|
|
14
14
|
var _chunkPY4R3IFFcjs = require('./chunk-PY4R3IFF.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
18
18
|
|
|
19
19
|
// src/charts/thematicmaps/ContiguousCartogram.ts
|
|
20
20
|
var _d3 = require('d3');
|
|
@@ -201,16 +201,16 @@ var ThematicSamples = (_class2 = class _ThematicSamples {
|
|
|
201
201
|
static __initStatic() {this.years = ["2017", "2018", "2019", "2020", "2021", "2022", "2023", "2024", "2025", "2026"]}
|
|
202
202
|
/** World regions with a rate in `value` and a skewed, population-like `weight` in millions. */
|
|
203
203
|
static weighted(seed) {
|
|
204
|
-
const { u, n } =
|
|
205
|
-
return reshape(
|
|
204
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed + 11);
|
|
205
|
+
return reshape(_chunk55767YPIcjs.GeoSamples.inhabited(seed), (feature, _lon, lat) => {
|
|
206
206
|
const settled = 0.05 + Math.exp(-(((Math.abs(lat) - 24) / 19) ** 2));
|
|
207
207
|
return { weight: +Math.max(0.1, _d3.geoArea.call(void 0, feature) ** 0.3 * 110 * settled * Math.exp(n() * 0.7) * (0.6 + u())).toFixed(1) };
|
|
208
208
|
});
|
|
209
209
|
}
|
|
210
210
|
/** World regions with `farming`, `industry` and `services` employment shares that sum to one. */
|
|
211
211
|
static sectors(seed) {
|
|
212
|
-
const { u } =
|
|
213
|
-
return reshape(
|
|
212
|
+
const { u } = _chunkLNWTC72Ycjs.SampleData.rng(seed + 23);
|
|
213
|
+
return reshape(_chunk55767YPIcjs.GeoSamples.inhabited(seed), (_feature, lon, lat) => {
|
|
214
214
|
const north = Math.min(1, Math.abs(lat) / 62), wave = 0.5 + 0.5 * Math.sin(lon / 34 + seed);
|
|
215
215
|
const raw = [0.03 + (1 - north) ** 2.4 * (0.3 + 0.9 * u()), 0.05 + 0.7 * wave ** 1.6 * (0.3 + 0.7 * u()), 0.06 + 0.9 * north ** 1.5 * (0.5 + 0.5 * u())];
|
|
216
216
|
const total = raw[0] + raw[1] + raw[2];
|
|
@@ -220,8 +220,8 @@ var ThematicSamples = (_class2 = class _ThematicSamples {
|
|
|
220
220
|
}
|
|
221
221
|
/** The 50 states and DC with a yearly rate in the `years` columns: a slow drift, a 2020 shock and an uneven recovery. */
|
|
222
222
|
static stateSeries(seed) {
|
|
223
|
-
const { u, n } =
|
|
224
|
-
return reshape(
|
|
223
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed + 37);
|
|
224
|
+
return reshape(_chunk55767YPIcjs.GeoSamples.usStates(seed), (_feature, lon, lat) => {
|
|
225
225
|
const base = 3.2 + 2.6 * (0.5 + 0.5 * Math.sin(lon / 9 + seed) * Math.cos(lat / 7)) + u() * 1.2;
|
|
226
226
|
const drift = (u() - 0.55) * 0.5, shock = 2.2 + u() * 4.5, recovery = 0.35 + u() * 0.4;
|
|
227
227
|
return Object.fromEntries(_ThematicSamples.years.map((year, i) => {
|
|
@@ -232,8 +232,8 @@ var ThematicSamples = (_class2 = class _ThematicSamples {
|
|
|
232
232
|
}
|
|
233
233
|
/** The 50 states and DC with invented resident counts in `value` (millions) and a 0 to 100 `rate`. */
|
|
234
234
|
static statePopulation(seed) {
|
|
235
|
-
const { u, n } =
|
|
236
|
-
return reshape(
|
|
235
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed + 51);
|
|
236
|
+
return reshape(_chunk55767YPIcjs.GeoSamples.usStates(seed), (feature, lon, lat) => {
|
|
237
237
|
const coast = 0.35 + 0.65 * Math.abs(Math.cos((lon + 97) / 21)), remote = lat > 50 ? 0.12 : 1;
|
|
238
238
|
const rate = _optionalChain([feature, 'access', _2 => _2.properties, 'optionalAccess', _3 => _3.value]);
|
|
239
239
|
return { rate, value: +Math.max(0.3, 95 * _d3.geoArea.call(void 0, feature) ** 0.6 * coast * remote * Math.exp(n() * 0.75) * (0.5 + 1.2 * u())).toFixed(1) };
|
|
@@ -241,8 +241,8 @@ var ThematicSamples = (_class2 = class _ThematicSamples {
|
|
|
241
241
|
}
|
|
242
242
|
/** Trips between twenty cities as a graph: nodes carry `lon` and `lat`, links a gravity-model `value`. */
|
|
243
243
|
static flows(seed) {
|
|
244
|
-
const { u } =
|
|
245
|
-
const cities =
|
|
244
|
+
const { u } = _chunkLNWTC72Ycjs.SampleData.rng(seed + 67);
|
|
245
|
+
const cities = _chunkLNWTC72Ycjs.SampleData.cities(seed);
|
|
246
246
|
const nodes = cities.map((city) => ({ id: String(city.name), lon: +city.lon, lat: +city.lat, value: +city.value }));
|
|
247
247
|
const links = nodes.flatMap((from) => nodes.flatMap((to) => {
|
|
248
248
|
if (from === to) return [];
|
|
@@ -256,7 +256,7 @@ var ThematicSamples = (_class2 = class _ThematicSamples {
|
|
|
256
256
|
|
|
257
257
|
// src/charts/thematicmaps/ContiguousCartogram.ts
|
|
258
258
|
var finite = (raw) => raw === null || raw === void 0 || raw === "" || !Number.isFinite(+raw) ? null : +raw;
|
|
259
|
-
var ContiguousCartogram = (_class3 = class extends
|
|
259
|
+
var ContiguousCartogram = (_class3 = class extends _chunk55767YPIcjs.RegionMap {
|
|
260
260
|
static __initStatic2() {this.meta = {
|
|
261
261
|
id: "contiguous-cartogram",
|
|
262
262
|
name: "Contiguous cartogram",
|
|
@@ -279,7 +279,7 @@ var ContiguousCartogram = (_class3 = class extends _chunkRXIMEK6Ccjs.RegionMap {
|
|
|
279
279
|
return false;
|
|
280
280
|
}
|
|
281
281
|
keyHeight() {
|
|
282
|
-
return
|
|
282
|
+
return _chunk55767YPIcjs.GeoLegend.height;
|
|
283
283
|
}
|
|
284
284
|
/** The projected rings of a feature, as the path generator would draw them. */
|
|
285
285
|
outline(frame, feature) {
|
|
@@ -313,7 +313,7 @@ var ContiguousCartogram = (_class3 = class extends _chunkRXIMEK6Ccjs.RegionMap {
|
|
|
313
313
|
return regions.map((region, i) => ({ ...region, tone: tones[i], d: sheet.path(i), grown: before[i] > 0 ? after[i] / before[i] : 1, spot: sheet.room(i) }));
|
|
314
314
|
}
|
|
315
315
|
classes(tones) {
|
|
316
|
-
return new (0,
|
|
316
|
+
return new (0, _chunk55767YPIcjs.GeoClasses)(tones.filter((tone) => tone !== null));
|
|
317
317
|
}
|
|
318
318
|
drawMap(ctx, frame) {
|
|
319
319
|
const { ghost, labels, value, shade, code } = this.options, { theme, palette } = ctx;
|
|
@@ -341,7 +341,7 @@ var ContiguousCartogram = (_class3 = class extends _chunkRXIMEK6Ccjs.RegionMap {
|
|
|
341
341
|
}
|
|
342
342
|
drawKey(ctx, frame) {
|
|
343
343
|
const classes = this.classes(this.tones(this.regions()));
|
|
344
|
-
|
|
344
|
+
_chunk55767YPIcjs.GeoLegend.classes(ctx, frame, classes, (tone) => ctx.palette.sequential(classes.tone(tone)));
|
|
345
345
|
}
|
|
346
346
|
table() {
|
|
347
347
|
return { columns: ["name", this.options.value, this.options.shade], rows: this.regions().map((region) => [region.name, region.value, finite(region.row[this.options.shade])]) };
|
|
@@ -581,7 +581,7 @@ var LABEL_ROOM = 26;
|
|
|
581
581
|
var CHAR2 = 5.4;
|
|
582
582
|
var finite2 = (raw) => raw === null || raw === void 0 || raw === "" || !Number.isFinite(+raw) ? null : +raw;
|
|
583
583
|
var fixed = (value) => value.toFixed(1);
|
|
584
|
-
var SparklineMap = (_class5 = class extends
|
|
584
|
+
var SparklineMap = (_class5 = class extends _chunk55767YPIcjs.TileMap {
|
|
585
585
|
static __initStatic4() {this.meta = {
|
|
586
586
|
id: "sparkline-map",
|
|
587
587
|
name: "Sparkline map",
|
|
@@ -793,7 +793,7 @@ var TernaryChoroplethCentering = /* @__PURE__ */ ((TernaryChoroplethCentering2)
|
|
|
793
793
|
})(TernaryChoroplethCentering || {});
|
|
794
794
|
var CHAR3 = 5.4;
|
|
795
795
|
var percent = (share) => `${(share * 100).toFixed(1)}%`;
|
|
796
|
-
var TernaryChoropleth = (_class7 = class extends
|
|
796
|
+
var TernaryChoropleth = (_class7 = class extends _chunk55767YPIcjs.RegionMap {
|
|
797
797
|
static __initStatic6() {this.meta = {
|
|
798
798
|
id: "ternary-choropleth",
|
|
799
799
|
name: "Ternary choropleth",
|
|
@@ -858,7 +858,7 @@ var ValueByAlphaBase = /* @__PURE__ */ ((ValueByAlphaBase2) => {
|
|
|
858
858
|
var CELL = 12;
|
|
859
859
|
var FAINTEST = 0.15;
|
|
860
860
|
var finite3 = (raw) => raw === null || raw === void 0 || raw === "" || !Number.isFinite(+raw) ? null : +raw;
|
|
861
|
-
var ValueByAlphaMap = (_class8 = class extends
|
|
861
|
+
var ValueByAlphaMap = (_class8 = class extends _chunk55767YPIcjs.RegionMap {
|
|
862
862
|
static __initStatic7() {this.meta = {
|
|
863
863
|
id: "value-by-alpha-map",
|
|
864
864
|
name: "Value-by-alpha map",
|
|
@@ -905,8 +905,8 @@ var ValueByAlphaMap = (_class8 = class extends _chunkRXIMEK6Ccjs.RegionMap {
|
|
|
905
905
|
drawMap(ctx, frame) {
|
|
906
906
|
const { classification, bins, levels, value, weight } = this.options, { theme } = ctx;
|
|
907
907
|
const regions = this.weighted(), paired = regions.filter((region) => region.value !== null && region.weight !== null);
|
|
908
|
-
const values = new (0,
|
|
909
|
-
const weights = new (0,
|
|
908
|
+
const values = new (0, _chunk55767YPIcjs.GeoClasses)(paired.map((region) => region.value), classification, bins);
|
|
909
|
+
const weights = new (0, _chunk55767YPIcjs.GeoClasses)(paired.map((region) => Math.abs(region.weight)), "quantile" /* Quantile */, levels);
|
|
910
910
|
const tone = this.tones(ctx, values), alpha = this.alpha(weights), base = this.base(ctx);
|
|
911
911
|
const edge = base === theme.surface ? theme.grid : theme.surface;
|
|
912
912
|
const outline = (d) => _nullishCoalesce(frame.path(d.feature), () => ( ""));
|
|
@@ -15,7 +15,7 @@ var _chunkEEF5WRRZcjs = require('./chunk-EEF5WRRZ.cjs');
|
|
|
15
15
|
var _chunkPY4R3IFFcjs = require('./chunk-PY4R3IFF.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
19
19
|
|
|
20
20
|
// src/charts/frameworks/raciEnums.ts
|
|
21
21
|
var RaciLetter = /* @__PURE__ */ ((RaciLetter2) => {
|
|
@@ -717,7 +717,7 @@ var BANDS = ["Detractors" /* Detractors */, "Passives" /* Passives */, "Promoter
|
|
|
717
717
|
var CELLS = Array.from({ length: 20 }, (_, i) => -100 + i * 10);
|
|
718
718
|
var percent = (value) => `${value.toFixed(1)}%`;
|
|
719
719
|
var bar = (x, y, w, h, [tl, tr, br, bl]) => `M${x + tl},${y}H${x + w - tr}Q${x + w},${y} ${x + w},${y + tr}V${y + h - br}Q${x + w},${y + h} ${x + w - br},${y + h}H${x + bl}Q${x},${y + h} ${x},${y + h - bl}V${y + tl}Q${x},${y} ${x + tl},${y}Z`;
|
|
720
|
-
var syntheticResponses = (seed) =>
|
|
720
|
+
var syntheticResponses = (seed) => _chunkLNWTC72Ycjs.SampleData.distribution(seed, 400, 1).map((row) => {
|
|
721
721
|
const z = (row.value - 40) / 8;
|
|
722
722
|
return { score: Math.max(0, Math.min(10, Math.round(8.1 + 1.9 * z - 0.3 * z * z))) };
|
|
723
723
|
});
|
|
@@ -994,7 +994,7 @@ var MOST_LANES = 2;
|
|
|
994
994
|
var CHAR2 = 6.2;
|
|
995
995
|
var money = (value) => value.toLocaleString("en", { maximumFractionDigits: 2 });
|
|
996
996
|
var syntheticResponses2 = (seed) => {
|
|
997
|
-
const draws =
|
|
997
|
+
const draws = _chunkLNWTC72Ycjs.SampleData.distribution(seed, 1500, 1).map((row) => (row.value - 40) / 8);
|
|
998
998
|
const stated = (value) => Math.max(0, Math.round(value / 5) * 5);
|
|
999
999
|
return Array.from({ length: 300 }, (_, i) => {
|
|
1000
1000
|
const z = draws.slice(i * 5, i * 5 + 5), anchor = 40 + 13 * Math.max(-2, Math.min(2, z[0]));
|
|
@@ -16,7 +16,7 @@ var _chunkUXFWDEP6cjs = require('./chunk-UXFWDEP6.cjs');
|
|
|
16
16
|
var _chunkAL4XQZH6cjs = require('./chunk-AL4XQZH6.cjs');
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
var
|
|
19
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
20
20
|
|
|
21
21
|
// src/charts/analysischarts/EventStudyPlot.ts
|
|
22
22
|
var _d3 = require('d3');
|
|
@@ -285,7 +285,7 @@ function cycleShape(months) {
|
|
|
285
285
|
var AnalysisSamples = class {
|
|
286
286
|
/** `period`, `estimate`, `se`, `series`: a staggered adoption estimated two ways, with the omitted period left out. */
|
|
287
287
|
static eventStudy(seed) {
|
|
288
|
-
const { n } =
|
|
288
|
+
const { n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
289
289
|
const truth = (t) => t < 0 ? 0 : 0.42 * (1 - Math.exp(-(t + 1) / 2.6));
|
|
290
290
|
return [["TWFE", 1], ["Callaway-Sant'Anna", 0]].flatMap(([series, biased]) => {
|
|
291
291
|
const rows = [];
|
|
@@ -299,7 +299,7 @@ var AnalysisSamples = class {
|
|
|
299
299
|
}
|
|
300
300
|
/** `x` running variable and `y` outcome, with a jump at zero. */
|
|
301
301
|
static discontinuity(seed) {
|
|
302
|
-
const { u, n } =
|
|
302
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
303
303
|
return Array.from({ length: 640 }, () => {
|
|
304
304
|
const x = 2 * u() - 1;
|
|
305
305
|
return { x: round(x), y: round(0.45 + 0.5 * x - 0.32 * x * x + (x >= 0 ? 0.28 : 0) + 0.11 * n()) };
|
|
@@ -307,7 +307,7 @@ var AnalysisSamples = class {
|
|
|
307
307
|
}
|
|
308
308
|
/** One row per specification: `estimate`, `se` and one column per analysis choice. */
|
|
309
309
|
static specifications(seed) {
|
|
310
|
-
const { n } =
|
|
310
|
+
const { n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
311
311
|
const rows = [];
|
|
312
312
|
for (const outcome of SPEC_CHOICES.outcome) for (const controls of SPEC_CHOICES.controls) for (const sample of SPEC_CHOICES.sample) for (const model of SPEC_CHOICES.model) {
|
|
313
313
|
const effect = 0.06 + (outcome === "Log earnings" ? 0.03 : 0) - SPEC_CHOICES.controls.indexOf(controls) * 0.035 + (sample === "All workers" ? 0.02 : 0) + (model === "Fixed effects" ? -0.025 : 0) + 0.018 * n();
|
|
@@ -317,7 +317,7 @@ var AnalysisSamples = class {
|
|
|
317
317
|
}
|
|
318
318
|
/** `covariate`, `sample` (Unadjusted or Adjusted) and `smd`, the standardised mean difference. */
|
|
319
319
|
static balance(seed) {
|
|
320
|
-
const { u, n } =
|
|
320
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
321
321
|
return COVARIATES.flatMap((covariate, i) => {
|
|
322
322
|
const before = (u() < 0.5 ? -1 : 1) * (0.05 + 0.45 * u() * (i < 5 ? 1 : 0.6));
|
|
323
323
|
const after = before * (0.05 + 0.25 * u()) + 0.02 * n();
|
|
@@ -326,7 +326,7 @@ var AnalysisSamples = class {
|
|
|
326
326
|
}
|
|
327
327
|
/** `time`, `unit`, `actual`, `synthetic`: one treated region from 2000 and donor placebos, each with its own synthetic control. */
|
|
328
328
|
static syntheticControl(seed) {
|
|
329
|
-
const { u, n } =
|
|
329
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
330
330
|
const units = ["Treated region", ...Array.from({ length: DONORS }, (_, i) => `Donor ${String(i + 1).padStart(2, "0")}`)];
|
|
331
331
|
return units.flatMap((unit, index) => {
|
|
332
332
|
const level = 110 + 30 * u(), slope = -1.4 - 1.2 * u(), fit = index === 0 ? 1.1 : index % 6 === 5 ? 6 + 6 * u() : 0.8 + 2.4 * u();
|
|
@@ -341,7 +341,7 @@ var AnalysisSamples = class {
|
|
|
341
341
|
}
|
|
342
342
|
/** `departure`, `arrival` (Dates), `c3` (km²/s²) and `vinf` (km/s) for direct Earth to Mars transfers on a grid. */
|
|
343
343
|
static porkchop(seed) {
|
|
344
|
-
const { u } =
|
|
344
|
+
const { u } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
345
345
|
const first = MARS_WINDOWS[Math.floor(u() * MARS_WINDOWS.length)], rows = [];
|
|
346
346
|
for (let i = 0; i < GRID; i++) for (let j = 0; j < GRID; j++) {
|
|
347
347
|
const departure = first + i * 3.5 * SECONDS_PER_DAY * 1e3, arrival = first + (110 + j * 7.5) * SECONDS_PER_DAY * 1e3;
|
|
@@ -352,7 +352,7 @@ var AnalysisSamples = class {
|
|
|
352
352
|
}
|
|
353
353
|
/** `date`, `latitude` (degrees), `area` (millionths of a hemisphere) and `cycle` for each new sunspot group. */
|
|
354
354
|
static sunspots(seed) {
|
|
355
|
-
const { u, n } =
|
|
355
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
356
356
|
const rows = [];
|
|
357
357
|
const step = CARRINGTON * SECONDS_PER_DAY * 1e3;
|
|
358
358
|
for (const [cycle, start, peak] of CYCLES) {
|
|
@@ -373,7 +373,7 @@ var AnalysisSamples = class {
|
|
|
373
373
|
}
|
|
374
374
|
/** `epoch`, `observed` (BJD of minimum), `type` (Primary or Secondary) and `error` (days) for an eclipsing binary. */
|
|
375
375
|
static minima(seed) {
|
|
376
|
-
const { u, n } =
|
|
376
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
377
377
|
const period = 0.8237465, t0 = 24510004231e-4;
|
|
378
378
|
const rows = [];
|
|
379
379
|
for (let epoch = -2600; epoch <= 13800; epoch += Math.round(40 + 220 * u())) {
|
|
@@ -386,7 +386,7 @@ var AnalysisSamples = class {
|
|
|
386
386
|
}
|
|
387
387
|
/** `object`, `period` (min), `apogee`, `perigee` (km) for fragments of a breakup near 850 km. */
|
|
388
388
|
static debris(seed) {
|
|
389
|
-
const { u, n } =
|
|
389
|
+
const { u, n } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
390
390
|
const radius = EARTH_RADIUS + 846, speed = Math.sqrt(MU_EARTH / radius) * 1.0012;
|
|
391
391
|
const rows = [];
|
|
392
392
|
for (let k = 0; rows.length < 180 && k < 400; k++) {
|
|
@@ -399,7 +399,7 @@ var AnalysisSamples = class {
|
|
|
399
399
|
}
|
|
400
400
|
/** `body`, `distance` (AU) and `vinf` (km/s): one row per Tisserand contour, at the planets' mean distances. */
|
|
401
401
|
static tisserand(seed) {
|
|
402
|
-
const { u } =
|
|
402
|
+
const { u } = _chunkLNWTC72Ycjs.SampleData.rng(seed);
|
|
403
403
|
const speeds = u() < 0.5 ? [3, 5, 7, 9] : [2, 4, 6, 8];
|
|
404
404
|
return [["Venus", 0.72333566], ["Earth", 1.00000261], ["Mars", 1.52371034], ["Jupiter", 5.202887]].flatMap(([body, distance]) => speeds.map((vinf) => ({ body, distance, vinf })));
|
|
405
405
|
}
|
|
@@ -23,7 +23,7 @@ var _chunkPY4R3IFFcjs = require('./chunk-PY4R3IFF.cjs');
|
|
|
23
23
|
var _chunk35CT4Q2Ecjs = require('./chunk-35CT4Q2E.cjs');
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
26
|
+
var _chunkLNWTC72Ycjs = require('./chunk-LNWTC72Y.cjs');
|
|
27
27
|
|
|
28
28
|
// src/charts/bars/BarChart.ts
|
|
29
29
|
var _d3 = require('d3');
|
|
@@ -36,7 +36,7 @@ var BarChart = (_class = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
36
36
|
shape: "table" /* Table */,
|
|
37
37
|
description: "Compares a value across categories using bar length, for ranking and part-of-total reading.",
|
|
38
38
|
tags: ["column", "grouped", "stacked"],
|
|
39
|
-
sample: (seed) =>
|
|
39
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed),
|
|
40
40
|
variants: {
|
|
41
41
|
orientation: ["vertical" /* Vertical */, "horizontal" /* Horizontal */],
|
|
42
42
|
stack: ["grouped" /* None */, "stacked" /* Stacked */, "normalized" /* Normalized */],
|
|
@@ -204,7 +204,7 @@ var FLOOR = 2;
|
|
|
204
204
|
var DECAY = 0.5;
|
|
205
205
|
var BarRaceSample = class {
|
|
206
206
|
static rows(seed) {
|
|
207
|
-
return
|
|
207
|
+
return _chunkLNWTC72Ycjs.SampleData.timeSeries(seed, DAYS, ENTITIES).flatMap((row, i) => {
|
|
208
208
|
const day = i % DAYS, entity = (i - day) / DAYS;
|
|
209
209
|
if (day % EVERY) return [];
|
|
210
210
|
return [{ ...row, value: +Math.max(FLOOR, (+row.value - entity * SPACING) * (1 - DECAY * day / (DAYS - 1))).toFixed(2) }];
|
|
@@ -546,7 +546,7 @@ var ButterflyChart = (_class3 = class extends MirrorChart {
|
|
|
546
546
|
shape: "table" /* Table */,
|
|
547
547
|
description: "Mirrors two groups around a central spine, and sorts into a tornado to rank the widest effects.",
|
|
548
548
|
tags: ["tornado", "back to back", "mirror", "sensitivity"],
|
|
549
|
-
sample: (seed) =>
|
|
549
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 9, 2).map((row) => row.series === "Bravo" ? { ...row, value: Math.round(+row.value * 0.6) } : row),
|
|
550
550
|
variants: {
|
|
551
551
|
gutter: [true, false],
|
|
552
552
|
sort: ["data" /* Data */, "total" /* Total */, "gap" /* Gap */, "left" /* Left */, "right" /* Right */],
|
|
@@ -594,7 +594,7 @@ var DateBarChart = (_class4 = class extends _chunkXX2YTCORcjs.CartesianChart {
|
|
|
594
594
|
shape: "table" /* Table */,
|
|
595
595
|
description: "Buckets dated rows into days, weeks or months and draws each bar across its real span of the calendar.",
|
|
596
596
|
tags: ["time", "calendar", "column", "volume"],
|
|
597
|
-
sample: (seed) =>
|
|
597
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.timeSeries(seed, 90, 3),
|
|
598
598
|
variants: {
|
|
599
599
|
interval: ["week" /* Week */, "day" /* Day */, "month" /* Month */],
|
|
600
600
|
stack: ["stacked" /* Stacked */, "normalized" /* Normalized */, "grouped" /* None */],
|
|
@@ -723,7 +723,7 @@ var DivergingBarChart = (_class5 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
723
723
|
shape: "table" /* Table */,
|
|
724
724
|
description: "Splits bars at a neutral centre so direction and size read together, including centred Likert stacks.",
|
|
725
725
|
tags: ["deviation", "likert", "sentiment", "net"],
|
|
726
|
-
sample: (seed) =>
|
|
726
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 7, 5).map((row) => ({ ...row, value: +row.value - 68 })),
|
|
727
727
|
variants: {
|
|
728
728
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
729
729
|
layout: ["net" /* Net */, "stacked" /* Stacked */, "likert" /* Likert */],
|
|
@@ -895,7 +895,7 @@ var DotPlot = (_class6 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
895
895
|
shape: "table" /* Table */,
|
|
896
896
|
description: "Positions dots along a shared scale so differences between series read without bars or a zero baseline.",
|
|
897
897
|
tags: ["cleveland", "dot", "strip"],
|
|
898
|
-
sample: (seed) =>
|
|
898
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 8, 3),
|
|
899
899
|
variants: {
|
|
900
900
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
901
901
|
sort: ["data" /* Data */, "descending" /* Descending */],
|
|
@@ -993,7 +993,7 @@ var DumbbellChart = (_class7 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
993
993
|
shape: "table" /* Table */,
|
|
994
994
|
description: "Joins two values per category so the size and direction of each gap reads directly.",
|
|
995
995
|
tags: ["connected dot", "gap", "before after"],
|
|
996
|
-
sample: (seed) =>
|
|
996
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 8, 2),
|
|
997
997
|
variants: {
|
|
998
998
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
999
999
|
sort: ["data" /* Data */, "gap" /* Gap */, "start" /* Start */, "end" /* End */],
|
|
@@ -1101,7 +1101,7 @@ var FacetedBarChart = (_class8 = class extends _chunkEEF5WRRZcjs.Chart2D {
|
|
|
1101
1101
|
shape: "table" /* Table */,
|
|
1102
1102
|
description: "Splits one bar chart into aligned panels per series, so each profile reads alone on a common frame.",
|
|
1103
1103
|
tags: ["small multiples", "trellis", "panels"],
|
|
1104
|
-
sample: (seed) =>
|
|
1104
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 6, 3),
|
|
1105
1105
|
variants: {
|
|
1106
1106
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
1107
1107
|
scale: ["shared" /* Shared */, "free" /* Free */],
|
|
@@ -1213,7 +1213,7 @@ var FacetedBarChart = (_class8 = class extends _chunkEEF5WRRZcjs.Chart2D {
|
|
|
1213
1213
|
// src/charts/bars/GroupedStackedBar.ts
|
|
1214
1214
|
|
|
1215
1215
|
var SCENARIOS = ["Plan", "Actual", "Forecast"];
|
|
1216
|
-
var sample = (seed) =>
|
|
1216
|
+
var sample = (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 5, 6).map((row, i) => ({ category: row.category, group: SCENARIOS[Math.floor(i / 2) % 3], series: i % 2 ? "Online" : "Retail", value: row.value }));
|
|
1217
1217
|
var GroupedStackedBar = (_class9 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
1218
1218
|
static __initStatic9() {this.meta = {
|
|
1219
1219
|
id: "bar-grouped-stacked",
|
|
@@ -1360,7 +1360,7 @@ var IconlessRankBar = (_class10 = class extends _chunkEEF5WRRZcjs.Chart2D {
|
|
|
1360
1360
|
shape: "table" /* Table */,
|
|
1361
1361
|
description: "Turns a ranking into a readable list of numbered rows with proportional bars, for leaderboards and top-N panels.",
|
|
1362
1362
|
tags: ["leaderboard", "top n", "list", "ranking"],
|
|
1363
|
-
sample: (seed) =>
|
|
1363
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 12, 1),
|
|
1364
1364
|
variants: {
|
|
1365
1365
|
layout: ["inline" /* Inline */, "stacked" /* Stacked */, "inside" /* Inside */],
|
|
1366
1366
|
top: [8, 5, 12],
|
|
@@ -1445,7 +1445,7 @@ var LollipopChart = (_class11 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
1445
1445
|
shape: "table" /* Table */,
|
|
1446
1446
|
description: "Ranks categories with a stem and head, trading bar weight for a cleaner read of many values.",
|
|
1447
1447
|
tags: ["stem", "ranking", "deviation"],
|
|
1448
|
-
sample: (seed) =>
|
|
1448
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 9, 3),
|
|
1449
1449
|
variants: {
|
|
1450
1450
|
orientation: ["vertical" /* Vertical */, "horizontal" /* Horizontal */],
|
|
1451
1451
|
sort: ["data" /* Data */, "descending" /* Descending */, "ascending" /* Ascending */],
|
|
@@ -1540,7 +1540,7 @@ var PercentChangeBar = (_class12 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
1540
1540
|
shape: "table" /* Table */,
|
|
1541
1541
|
description: "Plots the signed change of each category between two periods as percent, absolute or fold change.",
|
|
1542
1542
|
tags: ["delta", "growth", "year over year", "variance"],
|
|
1543
|
-
sample: (seed) =>
|
|
1543
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 8, 2),
|
|
1544
1544
|
variants: {
|
|
1545
1545
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
1546
1546
|
sort: ["data" /* Data */, "descending" /* Descending */, "ascending" /* Ascending */],
|
|
@@ -1653,7 +1653,7 @@ var PercentChangeBar = (_class12 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
1653
1653
|
|
|
1654
1654
|
// src/charts/bars/PopulationPyramid.ts
|
|
1655
1655
|
var WIDTH = 5;
|
|
1656
|
-
var cohorts = (seed) =>
|
|
1656
|
+
var cohorts = (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 12, 2).map((row, i) => {
|
|
1657
1657
|
const band = Math.floor(i / 2);
|
|
1658
1658
|
return { category: `${band * WIDTH}\u2013${band * WIDTH + WIDTH - 1}`, series: row.series, value: Math.round((12 - band) ** 1.4 * 12 + +row.value) };
|
|
1659
1659
|
});
|
|
@@ -1733,7 +1733,7 @@ var ProgressBars = (_class14 = class extends _chunkEEF5WRRZcjs.Chart2D {
|
|
|
1733
1733
|
shape: "table" /* Table */,
|
|
1734
1734
|
description: "Fills each item along a fixed track so remaining work is as visible as finished work.",
|
|
1735
1735
|
tags: ["completion", "track", "meter", "status"],
|
|
1736
|
-
sample: (seed) =>
|
|
1736
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.tasks(seed, 6),
|
|
1737
1737
|
variants: {
|
|
1738
1738
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
1739
1739
|
track: ["solid" /* Solid */, "segmented" /* Segmented */, "thin" /* Thin */],
|
|
@@ -1877,7 +1877,7 @@ var RangeBarChart = (_class15 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
1877
1877
|
shape: "table" /* Table */,
|
|
1878
1878
|
description: "Floats a bar between each category\u2019s low and high, either supplied or summarised from raw rows.",
|
|
1879
1879
|
tags: ["floating", "span", "interval", "column range"],
|
|
1880
|
-
sample: (seed) =>
|
|
1880
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.distribution(seed, 60, 7),
|
|
1881
1881
|
variants: {
|
|
1882
1882
|
orientation: ["horizontal" /* Horizontal */, "vertical" /* Vertical */],
|
|
1883
1883
|
spread: ["extent" /* Extent */, "interquartile" /* Interquartile */, "decile" /* Decile */, "deviation" /* Deviation */],
|
|
@@ -1993,7 +1993,7 @@ var TripleBarOverlay = (_class16 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
|
1993
1993
|
shape: "table" /* Table */,
|
|
1994
1994
|
description: "Layers three measures of one category in nested bars so each reads against the others at the same spot.",
|
|
1995
1995
|
tags: ["nested", "overlay", "budget actual", "bar in bar"],
|
|
1996
|
-
sample: (seed) =>
|
|
1996
|
+
sample: (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 7, 3),
|
|
1997
1997
|
variants: {
|
|
1998
1998
|
orientation: ["vertical" /* Vertical */, "horizontal" /* Horizontal */],
|
|
1999
1999
|
nesting: ["centered" /* Centered */, "stepped" /* Stepped */, "edge" /* Edge */],
|
|
@@ -2075,7 +2075,7 @@ var WaterfallChartStep = /* @__PURE__ */ ((WaterfallChartStep2) => {
|
|
|
2075
2075
|
WaterfallChartStep2["Arrow"] = "arrow";
|
|
2076
2076
|
return WaterfallChartStep2;
|
|
2077
2077
|
})(WaterfallChartStep || {});
|
|
2078
|
-
var reshape = (seed) =>
|
|
2078
|
+
var reshape = (seed) => _chunkLNWTC72Ycjs.SampleData.categories(seed, 8, 1).map((row, i) => ({ ...row, value: i ? (+row.value - 58) * 1.4 | 0 : +row.value + 120 }));
|
|
2079
2079
|
var WaterfallChart = (_class17 = class extends _chunkSRQSXNSPcjs.BandChart {
|
|
2080
2080
|
static __initStatic17() {this.meta = {
|
|
2081
2081
|
id: "bar-waterfall",
|