Skip to content

Commit 30534e3

Browse files
committed
aog wip
1 parent 9de8618 commit 30534e3

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

src/data_visualization/aog_in_clojure_part1.clj

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@
342342

343343
;; Nested structure requires a custom `merge-layer` function. Not ideal.
344344

345-
;; ### 📖 The Solution: Flat Structure with Disticnctive Keys
345+
;; ### 📖 The Solution: Flat Structure with Distinctive Keys
346346

347347
(def flat-layer-example
348348
{:=data {:bill-length-mm [39.1 39.5 40.3]
@@ -1300,7 +1300,10 @@ mtcars
13001300

13011301
iris
13021302

1303-
;; # Constants
1303+
;; # Visual Theme Constants
1304+
;;
1305+
;; These constants define the ggplot2-compatible visual theme used across
1306+
;; all rendering targets. Extracted here for maintainability.
13041307

13051308
;; ggplot2-compatible color palette for categorical variables
13061309
(def ggplot2-colors
@@ -2027,6 +2030,8 @@ iris
20272030

20282031
(kind/html (svg/serialize svg-elem))))))
20292032

2033+
;; We now have enough implementation to show basic scatter plots.
2034+
20302035
;; # Basic Scatter Plots
20312036
;;
20322037
;; Simple scatter plots demonstrating the core API.
@@ -2261,6 +2266,8 @@ iris
22612266
;; Notice: Type inference is instant (O(1) lookup from Tablecloth metadata),
22622267
;; not O(n) value examination.
22632268

2269+
;; With linear regression implemented, we can overlay trend lines.
2270+
22642271
;; # Linear Regression
22652272
;;
22662273
;; Statistical transformation: computing and overlaying regression lines.
@@ -2448,6 +2455,8 @@ iris
24482455
(and (map? (meta rendered))
24492456
(= (:kindly/kind (meta rendered)) :kind/html))))])
24502457

2458+
;; Histograms demonstrate statistical transforms that derive new data from the input.
2459+
24512460
;; # Histograms
24522461
;;
24532462
;; Statistical transformation: binning continuous data and counting occurrences.
@@ -3651,6 +3660,8 @@ iris
36513660
;; - Minimal delegation keeps implementation focused
36523661
;; - Backend-agnostic IR enables multiple rendering strategies
36533662

3663+
;; Now we can demonstrate multi-target rendering with the same spec.
3664+
36543665
;; # Plotly.js Target Examples
36553666
;;
36563667
;; Now let's explore the `:plotly` target, which provides interactivity

0 commit comments

Comments
 (0)