diff --git a/plots/alluvial-basic/implementations/python/plotly.py b/plots/alluvial-basic/implementations/python/plotly.py index 4d9797424b..5a208a79b1 100644 --- a/plots/alluvial-basic/implementations/python/plotly.py +++ b/plots/alluvial-basic/implementations/python/plotly.py @@ -18,7 +18,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data: Browser market share evolution 2015-2024 # Shows how different browsers have gained/lost market share over time @@ -27,7 +27,7 @@ # Node labels and colors node_labels = categories * 4 -category_colors = {cat: OKABE_ITO[i] for i, cat in enumerate(categories)} +category_colors = {cat: IMPRINT[i] for i, cat in enumerate(categories)} node_colors = [category_colors[cat] for cat in node_labels] # X positions: 4 time points evenly spaced @@ -85,7 +85,7 @@ targets.append(tgt_idx) values.append(value) # Use source category color with transparency - base_color = OKABE_ITO[src_cat] + base_color = IMPRINT[src_cat] r = int(base_color[1:3], 16) g = int(base_color[3:5], 16) b = int(base_color[5:7], 16) diff --git a/plots/andrews-curves/implementations/python/plotly.py b/plots/andrews-curves/implementations/python/plotly.py index 97b4d396ca..8233a49580 100644 --- a/plots/andrews-curves/implementations/python/plotly.py +++ b/plots/andrews-curves/implementations/python/plotly.py @@ -18,8 +18,8 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] -BRAND = OKABE_ITO[0] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] +BRAND = IMPRINT[0] # Data iris = load_iris() @@ -57,7 +57,7 @@ x=t, y=curve, mode="lines", - line=dict(color=OKABE_ITO[species_idx], width=2), + line=dict(color=IMPRINT[species_idx], width=2), opacity=0.4, name=species_names[species_idx], legendgroup=species_names[species_idx], diff --git a/plots/area-cumulative-flow/implementations/python/plotly.py b/plots/area-cumulative-flow/implementations/python/plotly.py index 6d599ca445..4d8d737e76 100644 --- a/plots/area-cumulative-flow/implementations/python/plotly.py +++ b/plots/area-cumulative-flow/implementations/python/plotly.py @@ -17,17 +17,17 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" # Okabe-Ito palette — first series is always #009E73 FILL_COLORS = [ - "rgba(0,158,115,0.80)", # #009E73 Done - "rgba(213,94,0,0.80)", # #D55E00 Testing - "rgba(0,114,178,0.80)", # #0072B2 Development - "rgba(204,121,167,0.80)", # #CC79A7 Analysis - "rgba(230,159,0,0.80)", # #E69F00 Backlog + "rgba(0, 158, 115, 0.80)", # #009E73 Done + "rgba(196, 117, 253, 0.80)", # #C475FD Testing + "rgba(68, 103, 163, 0.80)", # #4467A3 Development + "rgba(189, 130, 51, 0.80)", # #BD8233 Analysis + "rgba(174, 48, 48, 0.80)", # #AE3030 Backlog ] -LINE_COLORS = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +LINE_COLORS = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data — Kanban board for a software team over 90 days np.random.seed(42) diff --git a/plots/area-stacked-confidence/implementations/python/plotly.py b/plots/area-stacked-confidence/implementations/python/plotly.py index 0db561b827..d0b7319cdd 100644 --- a/plots/area-stacked-confidence/implementations/python/plotly.py +++ b/plots/area-stacked-confidence/implementations/python/plotly.py @@ -17,12 +17,12 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" # Okabe-Ito palette (positions 1-3 for three series) HYDRO_COLOR = "#009E73" # Okabe-Ito position 1 (brand green) -WIND_COLOR = "#D55E00" # Okabe-Ito position 2 (vermillion) -SOLAR_COLOR = "#0072B2" # Okabe-Ito position 3 (blue) +WIND_COLOR = "#C475FD" # Okabe-Ito position 2 (vermillion) +SOLAR_COLOR = "#4467A3" # Okabe-Ito position 3 (blue) # Data - Quarterly energy consumption forecast by source with uncertainty bands np.random.seed(42) @@ -67,7 +67,7 @@ y=list(hydro_upper_stack) + list(hydro_lower_stack[::-1]), fill="toself", fillcolor="rgba(0, 158, 115, 0.25)", - line=dict(color="rgba(255,255,255,0)"), + line=dict(color="rgba(255, 255, 255, 0)"), showlegend=False, name="Hydro Band", hoverinfo="skip", @@ -93,8 +93,8 @@ x=quarters + quarters[::-1], y=list(wind_upper_stack) + list(wind_lower_stack[::-1]), fill="toself", - fillcolor="rgba(213, 94, 0, 0.25)", - line=dict(color="rgba(255,255,255,0)"), + fillcolor="rgba(196, 117, 253, 0.25)", + line=dict(color="rgba(255, 255, 255, 0)"), showlegend=False, name="Wind Band", hoverinfo="skip", @@ -110,7 +110,7 @@ line=dict(color=WIND_COLOR, width=3), name="Wind", fill="tonexty", - fillcolor="rgba(213, 94, 0, 0.6)", + fillcolor="rgba(196, 117, 253, 0.6)", ) ) @@ -120,8 +120,8 @@ x=quarters + quarters[::-1], y=list(solar_upper_stack) + list(solar_lower_stack[::-1]), fill="toself", - fillcolor="rgba(0, 114, 178, 0.25)", - line=dict(color="rgba(255,255,255,0)"), + fillcolor="rgba(68, 103, 163, 0.25)", + line=dict(color="rgba(255, 255, 255, 0)"), showlegend=False, name="Solar Band", hoverinfo="skip", @@ -137,7 +137,7 @@ line=dict(color=SOLAR_COLOR, width=3), name="Solar", fill="tonexty", - fillcolor="rgba(0, 114, 178, 0.6)", + fillcolor="rgba(68, 103, 163, 0.6)", ) ) diff --git a/plots/area-stacked/implementations/python/plotly.py b/plots/area-stacked/implementations/python/plotly.py index b11e444c7d..7e104e44c1 100644 --- a/plots/area-stacked/implementations/python/plotly.py +++ b/plots/area-stacked/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always brand green) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Monthly revenue by product category over 2 years np.random.seed(42) @@ -48,9 +48,9 @@ y=software, name="Software", mode="lines", - line=dict(width=0.5, color=OKABE_ITO[0]), + line=dict(width=0.5, color=IMPRINT[0]), fill="tozeroy", - fillcolor=OKABE_ITO[0], + fillcolor=IMPRINT[0], stackgroup="one", hovertemplate="Software
%{x|%b %Y}
Revenue: $%{y:,.0f}", ) @@ -62,9 +62,9 @@ y=services, name="Services", mode="lines", - line=dict(width=0.5, color=OKABE_ITO[1]), + line=dict(width=0.5, color=IMPRINT[1]), fill="tonexty", - fillcolor=OKABE_ITO[1], + fillcolor=IMPRINT[1], stackgroup="one", hovertemplate="Services
%{x|%b %Y}
Revenue: $%{y:,.0f}", ) @@ -76,9 +76,9 @@ y=enterprise, name="Enterprise", mode="lines", - line=dict(width=0.5, color=OKABE_ITO[2]), + line=dict(width=0.5, color=IMPRINT[2]), fill="tonexty", - fillcolor=OKABE_ITO[2], + fillcolor=IMPRINT[2], stackgroup="one", hovertemplate="Enterprise
%{x|%b %Y}
Revenue: $%{y:,.0f}", ) @@ -90,9 +90,9 @@ y=consulting, name="Consulting", mode="lines", - line=dict(width=0.5, color=OKABE_ITO[3]), + line=dict(width=0.5, color=IMPRINT[3]), fill="tonexty", - fillcolor=OKABE_ITO[3], + fillcolor=IMPRINT[3], stackgroup="one", hovertemplate="Consulting
%{x|%b %Y}
Revenue: $%{y:,.0f}", ) diff --git a/plots/bar-3d-categorical/implementations/python/plotly.py b/plots/bar-3d-categorical/implementations/python/plotly.py index cbc0d39b5d..88dfc7bdc7 100644 --- a/plots/bar-3d-categorical/implementations/python/plotly.py +++ b/plots/bar-3d-categorical/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID_COLOR = "#D0CEC7" if THEME == "light" else "#2D2D2A" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data np.random.seed(42) @@ -64,7 +64,7 @@ i=ii, j=jj, k=kk, - color=OKABE_ITO[p_idx], + color=IMPRINT[p_idx], opacity=1.0, name=prod, showlegend=True, diff --git a/plots/bar-diverging/implementations/python/plotly.py b/plots/bar-diverging/implementations/python/plotly.py index d74de32fc4..0622a9c626 100644 --- a/plots/bar-diverging/implementations/python/plotly.py +++ b/plots/bar-diverging/implementations/python/plotly.py @@ -19,7 +19,7 @@ # Okabe-Ito palette: position 1 (green) for positive, position 2 (orange) for negative POSITIVE_COLOR = "#009E73" -NEGATIVE_COLOR = "#D55E00" +NEGATIVE_COLOR = "#AE3030" # imprint red — semantic negative # Data: Customer satisfaction survey results by department # Scores range from -100 (very dissatisfied) to +100 (very satisfied) diff --git a/plots/bar-drilldown/implementations/python/plotly.py b/plots/bar-drilldown/implementations/python/plotly.py index 96f80a38dc..161a200c3b 100644 --- a/plots/bar-drilldown/implementations/python/plotly.py +++ b/plots/bar-drilldown/implementations/python/plotly.py @@ -21,7 +21,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # anyplot palette — positions 1–4 for 4 quarters -PALETTE = ["#009E73", "#9418DB", "#B71D27", "#16B8F3"] +PALETTE = ["#009E73", "#C475FD", "#AE3030", "#4467A3"] # Data: 2024 Retail Sales — quarter → month two-level hierarchy QUARTERS = [ diff --git a/plots/bar-grouped/implementations/python/plotly.py b/plots/bar-grouped/implementations/python/plotly.py index 39d3b52d17..4c704b3e28 100644 --- a/plots/bar-grouped/implementations/python/plotly.py +++ b/plots/bar-grouped/implementations/python/plotly.py @@ -18,7 +18,7 @@ GRID = "rgba(26,26,23,0.20)" if THEME == "light" else "rgba(240,239,232,0.20)" # Okabe-Ito palette -COLORS = ["#009E73", "#D55E00", "#0072B2"] +COLORS = ["#009E73", "#C475FD", "#4467A3"] # Data: Quarterly revenue by product line categories = ["Q1", "Q2", "Q3", "Q4"] diff --git a/plots/bar-race-animated/implementations/python/plotly.py b/plots/bar-race-animated/implementations/python/plotly.py index cf89e8cd18..3b3814643e 100644 --- a/plots/bar-race-animated/implementations/python/plotly.py +++ b/plots/bar-race-animated/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.25)" if THEME == "light" else "rgba(240,239,232,0.25)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data: Major economy GDP rankings (approximate, in trillion USD, 1995–2023) np.random.seed(42) @@ -27,7 +27,7 @@ years = list(range(1995, 2024)) base_gdp = {"USA": 7.70, "China": 0.73, "Japan": 5.45, "Germany": 2.60, "UK": 1.28, "France": 1.60, "Brazil": 0.77} -color_map = dict(zip(countries, OKABE_ITO)) +color_map = dict(zip(countries, IMPRINT)) data_rows = [] for country in countries: diff --git a/plots/bar-spine/implementations/python/plotly.py b/plots/bar-spine/implementations/python/plotly.py index 2001eba76c..9020e3f7db 100644 --- a/plots/bar-spine/implementations/python/plotly.py +++ b/plots/bar-spine/implementations/python/plotly.py @@ -41,8 +41,8 @@ # Conditional proportions within each bar (heights sum to 1) outcome_props = {k: [cnt / m for cnt, m in zip(v, channel_sizes)] for k, v in outcome_counts.items()} -# Okabe-Ito palette: Active=green(1), On Trial=orange(5), Cancelled=vermillion(2) -COLORS = {"Active": "#009E73", "On Trial": "#E69F00", "Cancelled": "#D55E00"} +# imprint semantic anchors: Active=green, On Trial=amber (warning), Cancelled=red (bad) +COLORS = {"Active": "#009E73", "On Trial": "#DDCC77", "Cancelled": "#AE3030"} # Plot fig = go.Figure() diff --git a/plots/bar-stacked-labeled/implementations/python/plotly.py b/plots/bar-stacked-labeled/implementations/python/plotly.py index 4127138448..2d15bf2adc 100644 --- a/plots/bar-stacked-labeled/implementations/python/plotly.py +++ b/plots/bar-stacked-labeled/implementations/python/plotly.py @@ -22,7 +22,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is ALWAYS #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data: Quarterly revenue by product category quarters = ["Q1 2024", "Q2 2024", "Q3 2024", "Q4 2024", "Q1 2025"] @@ -43,7 +43,7 @@ fig = go.Figure() # Add stacked bars for each product -for product, color in zip(products, OKABE_ITO, strict=True): +for product, color in zip(products, IMPRINT, strict=True): fig.add_trace( go.Bar( name=product, diff --git a/plots/bar-stacked-percent/implementations/python/plotly.py b/plots/bar-stacked-percent/implementations/python/plotly.py index a2c9896e56..27e0a23f27 100644 --- a/plots/bar-stacked-percent/implementations/python/plotly.py +++ b/plots/bar-stacked-percent/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette - first color is always #009E73 -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data: Smartphone OS market share across world regions categories = ["North America", "South America", "Europe", "Africa", "Asia"] @@ -45,7 +45,7 @@ name=component, x=categories, y=df[component].values, - marker=dict(color=OKABE_ITO[i], line=dict(width=0)), + marker=dict(color=IMPRINT[i], line=dict(width=0)), text=[f"{v:.0f}%" for v in df[component].values], textposition="inside", textfont=dict(size=16, color="white"), diff --git a/plots/bar-stacked/implementations/python/plotly.py b/plots/bar-stacked/implementations/python/plotly.py index 3ea9816e23..69d35936a4 100644 --- a/plots/bar-stacked/implementations/python/plotly.py +++ b/plots/bar-stacked/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID_SUBTLE = "rgba(26,26,23,0.04)" if THEME == "light" else "rgba(240,239,232,0.04)" # Okabe-Ito palette (first series always #009E73) -COLORS = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +COLORS = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Quarterly revenue by product category quarters = ["Q1 2024", "Q2 2024", "Q3 2024", "Q4 2024"] diff --git a/plots/biplot-pca/implementations/python/plotly.py b/plots/biplot-pca/implementations/python/plotly.py index 91a943648e..4214e9c502 100644 --- a/plots/biplot-pca/implementations/python/plotly.py +++ b/plots/biplot-pca/implementations/python/plotly.py @@ -22,7 +22,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Load data iris = load_iris() @@ -52,7 +52,7 @@ x=scores[mask, 0], y=scores[mask, 1], mode="markers", - marker={"size": 14, "color": OKABE_ITO[i], "opacity": 0.8, "line": {"width": 1, "color": PAGE_BG}}, + marker={"size": 14, "color": IMPRINT[i], "opacity": 0.8, "line": {"width": 1, "color": PAGE_BG}}, name=target.capitalize(), legendgroup=target, ) diff --git a/plots/bland-altman-basic/implementations/python/plotly.py b/plots/bland-altman-basic/implementations/python/plotly.py index 0871ee1ee8..c3690af323 100644 --- a/plots/bland-altman-basic/implementations/python/plotly.py +++ b/plots/bland-altman-basic/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -ACCENT = "#D55E00" +ACCENT = "#C475FD" # Data - Glucose meter readings comparison (medical device validation) np.random.seed(73) diff --git a/plots/box-grouped/implementations/python/plotly.py b/plots/box-grouped/implementations/python/plotly.py index de03b6750d..d6a0e9593c 100644 --- a/plots/box-grouped/implementations/python/plotly.py +++ b/plots/box-grouped/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - Employee performance scores by department and experience level np.random.seed(42) @@ -73,7 +73,7 @@ x=x_vals, y=y_vals, name=subcat, - marker_color=OKABE_ITO[i], + marker_color=IMPRINT[i], boxmean=False, line={"width": 2}, marker={"size": 8, "opacity": 0.7}, diff --git a/plots/box-horizontal/implementations/python/plotly.py b/plots/box-horizontal/implementations/python/plotly.py index d1f60df922..6e795a207a 100644 --- a/plots/box-horizontal/implementations/python/plotly.py +++ b/plots/box-horizontal/implementations/python/plotly.py @@ -19,7 +19,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data - Response times (ms) by service type np.random.seed(42) @@ -64,9 +64,9 @@ x=service_data, name=service, orientation="h", - marker=dict(color=OKABE_ITO[i % len(OKABE_ITO)], size=8, outliercolor=OKABE_ITO[i % len(OKABE_ITO)]), - line=dict(color=OKABE_ITO[i % len(OKABE_ITO)], width=2), - fillcolor=OKABE_ITO[i % len(OKABE_ITO)], + marker=dict(color=IMPRINT[i % len(IMPRINT)], size=8, outliercolor=IMPRINT[i % len(IMPRINT)]), + line=dict(color=IMPRINT[i % len(IMPRINT)], width=2), + fillcolor=IMPRINT[i % len(IMPRINT)], opacity=0.7, boxmean=False, hovertemplate="%{name}
Value: %{x:.1f} ms", diff --git a/plots/box-notched/implementations/python/plotly.py b/plots/box-notched/implementations/python/plotly.py index 08d2bcac99..eff7ba1d72 100644 --- a/plots/box-notched/implementations/python/plotly.py +++ b/plots/box-notched/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data - Employee salary distributions across departments np.random.seed(42) @@ -48,9 +48,9 @@ name=dept, boxpoints="outliers", notched=True, - marker={"color": OKABE_ITO[i], "size": 10, "opacity": 0.7}, + marker={"color": IMPRINT[i], "size": 10, "opacity": 0.7}, line={"width": 2}, - fillcolor=OKABE_ITO[i], + fillcolor=IMPRINT[i], opacity=0.7, ) ) diff --git a/plots/bubble-map-geographic/implementations/python/plotly.py b/plots/bubble-map-geographic/implementations/python/plotly.py index 0352bf807c..875145f2c6 100644 --- a/plots/bubble-map-geographic/implementations/python/plotly.py +++ b/plots/bubble-map-geographic/implementations/python/plotly.py @@ -26,11 +26,11 @@ # Okabe-Ito palette for regions (canonical order, first = #009E73) REGION_COLORS = { "Asia": "#009E73", - "Europe": "#D55E00", - "North America": "#0072B2", - "South America": "#CC79A7", - "Africa": "#E69F00", - "Oceania": "#56B4E9", + "Europe": "#C475FD", + "North America": "#4467A3", + "South America": "#BD8233", + "Africa": "#AE3030", + "Oceania": "#2ABCCD", } REGION_ORDER = ["Asia", "Europe", "North America", "South America", "Africa", "Oceania"] diff --git a/plots/calibration-curve/implementations/python/plotly.py b/plots/calibration-curve/implementations/python/plotly.py index af0a95634d..09e044ff2a 100644 --- a/plots/calibration-curve/implementations/python/plotly.py +++ b/plots/calibration-curve/implementations/python/plotly.py @@ -19,7 +19,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -SECONDARY = "#D55E00" +SECONDARY = "#C475FD" NEUTRAL = "#1A1A1A" if THEME == "light" else "#E8E8E0" # Data - simulate predictions from two classifiers diff --git a/plots/candlestick-volume/implementations/python/plotly.py b/plots/candlestick-volume/implementations/python/plotly.py index d200a57187..d2a28db79f 100644 --- a/plots/candlestick-volume/implementations/python/plotly.py +++ b/plots/candlestick-volume/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" COLOR_UP = "#009E73" # Okabe-Ito position 1 (brand green) -COLOR_DOWN = "#D55E00" # Okabe-Ito position 2 (vermillion) +COLOR_DOWN = "#AE3030" # imprint red — down days # Data - Generate 60 trading days of realistic OHLC + volume data np.random.seed(42) diff --git a/plots/cat-box-strip/implementations/python/plotly.py b/plots/cat-box-strip/implementations/python/plotly.py index f7a0d64bf1..8e697e72c4 100644 --- a/plots/cat-box-strip/implementations/python/plotly.py +++ b/plots/cat-box-strip/implementations/python/plotly.py @@ -19,7 +19,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 -SERIES2 = "#D55E00" # Okabe-Ito position 2 +SERIES2 = "#C475FD" # Okabe-Ito position 2 # Data - Exam scores across different study methods np.random.seed(42) diff --git a/plots/chernoff-basic/implementations/python/plotly.py b/plots/chernoff-basic/implementations/python/plotly.py index 9670edf584..408f547a92 100644 --- a/plots/chernoff-basic/implementations/python/plotly.py +++ b/plots/chernoff-basic/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - use Iris dataset with 4 measurements per flower np.random.seed(42) @@ -75,7 +75,7 @@ cx = col * spacing + spacing / 2 cy = (n_rows - 1 - row) * spacing + spacing / 2 - color = OKABE_ITO[species] + color = IMPRINT[species] # Feature mapping with increased variation: # - sepal_length (data[0]) -> face width @@ -209,7 +209,7 @@ fig.add_trace(go.Scatter(x=[0], y=[0], mode="markers", marker=dict(opacity=0), showlegend=False)) # Add legend entries for species -for i, (name, color) in enumerate(zip(target_names, OKABE_ITO)): +for i, (name, color) in enumerate(zip(target_names, IMPRINT)): fig.add_trace( go.Scatter( x=[None], diff --git a/plots/circlepacking-basic/implementations/python/plotly.py b/plots/circlepacking-basic/implementations/python/plotly.py index d530add291..1c6e3cdb31 100644 --- a/plots/circlepacking-basic/implementations/python/plotly.py +++ b/plots/circlepacking-basic/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] np.random.seed(42) @@ -102,7 +102,7 @@ cx, cy = asset_info["x"], asset_info["y"] asset_radius = asset_info["r"] subcats = asset_info["subcats"] - asset_color = OKABE_ITO[idx % len(OKABE_ITO)] + asset_color = IMPRINT[idx % len(IMPRINT)] all_circles.append( { @@ -313,7 +313,7 @@ x=[None], y=[None], mode="markers", - marker={"size": 16, "color": OKABE_ITO[idx % len(OKABE_ITO)], "line": {"color": INK_SOFT, "width": 2}}, + marker={"size": 16, "color": IMPRINT[idx % len(IMPRINT)], "line": {"color": INK_SOFT, "width": 2}}, name=name, showlegend=True, ) diff --git a/plots/circos-basic/implementations/python/plotly.py b/plots/circos-basic/implementations/python/plotly.py index 88898d9004..47281797c8 100644 --- a/plots/circos-basic/implementations/python/plotly.py +++ b/plots/circos-basic/implementations/python/plotly.py @@ -30,14 +30,14 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito palette with first series as brand -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple - "#E69F00", # orange - "#56B4E9", # sky blue - "#F0E442", # yellow + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple + "#AE3030", # orange + "#2ABCCD", # sky blue + "#954477", # yellow "#1A1A1A" if THEME == "light" else "#E8E8E0", # neutral ] @@ -106,7 +106,7 @@ x=x_arc, y=y_arc, fill="toself", - fillcolor=OKABE_ITO[i], + fillcolor=IMPRINT[i], line={"color": INK_SOFT, "width": 1}, name=segments[i], hoverinfo="name", @@ -196,8 +196,8 @@ y_ribbon = np.concatenate([y_src, curve1_y, y_tgt, curve2_y, [y_src[0]]]) # Blend colors inline - c1 = OKABE_ITO[i] - c2 = OKABE_ITO[j] + c1 = IMPRINT[i] + c2 = IMPRINT[j] r1, g1, b1 = int(c1[1:3], 16), int(c1[3:5], 16), int(c1[5:7], 16) r2, g2, b2 = int(c2[1:3], 16), int(c2[3:5], 16), int(c2[5:7], 16) r = int(r1 * 0.5 + r2 * 0.5) @@ -244,7 +244,7 @@ x=x_bar, y=y_bar, fill="toself", - fillcolor=OKABE_ITO[i], + fillcolor=IMPRINT[i], opacity=0.6, line={"color": INK_SOFT, "width": 0.5}, hoverinfo="text", diff --git a/plots/contour-decision-boundary/implementations/python/plotly.py b/plots/contour-decision-boundary/implementations/python/plotly.py index 11777d8447..e13215baad 100644 --- a/plots/contour-decision-boundary/implementations/python/plotly.py +++ b/plots/contour-decision-boundary/implementations/python/plotly.py @@ -20,7 +20,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Generate moon-shaped classification data np.random.seed(42) @@ -52,7 +52,7 @@ x=np.linspace(x_min, x_max, 150), y=np.linspace(y_min, y_max, 150), z=Z_prob, - colorscale=[[0, OKABE_ITO[0]], [1, OKABE_ITO[1]]], + colorscale=[[0, IMPRINT[0]], [1, IMPRINT[1]]], opacity=0.4, showscale=True, colorbar=dict( @@ -90,7 +90,7 @@ x=X_class0[:, 0], y=X_class0[:, 1], mode="markers", - marker=dict(size=14, color=OKABE_ITO[0], line=dict(color=PAGE_BG, width=2), symbol="circle"), + marker=dict(size=14, color=IMPRINT[0], line=dict(color=PAGE_BG, width=2), symbol="circle"), name="Class 0", hovertemplate="Feature 1: %{x:.2f}
Feature 2: %{y:.2f}
Class: 0", ) @@ -102,7 +102,7 @@ x=X_class1[:, 0], y=X_class1[:, 1], mode="markers", - marker=dict(size=14, color=OKABE_ITO[1], line=dict(color=PAGE_BG, width=2), symbol="diamond"), + marker=dict(size=14, color=IMPRINT[1], line=dict(color=PAGE_BG, width=2), symbol="diamond"), name="Class 1", hovertemplate="Feature 1: %{x:.2f}
Feature 2: %{y:.2f}
Class: 1", ) diff --git a/plots/contour-density/implementations/python/plotly.py b/plots/contour-density/implementations/python/plotly.py index 1b36a2c678..5d97f2b73e 100644 --- a/plots/contour-density/implementations/python/plotly.py +++ b/plots/contour-density/implementations/python/plotly.py @@ -44,7 +44,7 @@ colorscale = [ [0, "rgba(255,255,255,0)"], # Transparent at low density [0.2, "#FDB462"], # Light orange (visible on both themes) - [0.5, "#0072B2"], # Blue (Okabe-Ito position 3) + [0.5, "#4467A3"], # Blue (Okabe-Ito position 3) [1, "#005073"], # Dark blue (increased contrast) ] diff --git a/plots/dashboard-synchronized-crosshair/implementations/python/plotly.py b/plots/dashboard-synchronized-crosshair/implementations/python/plotly.py index a5ccad66cf..1582065e40 100644 --- a/plots/dashboard-synchronized-crosshair/implementations/python/plotly.py +++ b/plots/dashboard-synchronized-crosshair/implementations/python/plotly.py @@ -22,8 +22,8 @@ # anyplot palette PRICE_COLOR = "#009E73" # position 1 - green -VOLUME_COLOR = "#9418DB" # position 2 - purple -RSI_COLOR = "#16B8F3" # position 4 - sky blue +VOLUME_COLOR = "#C475FD" # position 2 - purple +RSI_COLOR = "#4467A3" # position 4 - sky blue # Data - Stock data: price, volume, and 14-period RSI over 200 trading days np.random.seed(42) @@ -104,7 +104,7 @@ ) # RSI reference lines — distinct dash patterns for colorblind accessibility -fig.add_hline(y=70, line_dash="dash", line_color="#B71D27", line_width=1.5, row=3, col=1) +fig.add_hline(y=70, line_dash="dash", line_color="#AE3030", line_width=1.5, row=3, col=1) fig.add_hline(y=30, line_dash="dot", line_color="#009E73", line_width=1.5, row=3, col=1) # Style diff --git a/plots/dendrogram-radial/implementations/python/plotly.py b/plots/dendrogram-radial/implementations/python/plotly.py index 779c2124d0..fb0ff2570c 100644 --- a/plots/dendrogram-radial/implementations/python/plotly.py +++ b/plots/dendrogram-radial/implementations/python/plotly.py @@ -21,7 +21,7 @@ INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] SPECIES = ["Setosa", "Versicolor", "Virginica"] # Data: 12 samples per iris species (36 leaves total) @@ -82,7 +82,7 @@ def branch_color(node_id): sp = node_species[node_id] if len(sp) == 1: - return OKABE_ITO[next(iter(sp))] + return IMPRINT[next(iter(sp))] return INK_SOFT @@ -142,7 +142,7 @@ def branch_color(node_id): x=np.cos(leaf_rad), y=np.sin(leaf_rad), mode="markers", - marker={"color": [OKABE_ITO[y[i]] for i in range(n_leaves)], "size": 10, "line": {"color": PAGE_BG, "width": 1.5}}, + marker={"color": [IMPRINT[y[i]] for i in range(n_leaves)], "size": 10, "line": {"color": PAGE_BG, "width": 1.5}}, showlegend=False, hovertext=[f"{labels[i]} · {SPECIES[y[i]]}" for i in range(n_leaves)], hoverinfo="text", @@ -156,8 +156,8 @@ def branch_color(node_id): x=[None], y=[None], mode="markers+lines", - marker={"color": OKABE_ITO[idx], "size": 12}, - line={"color": OKABE_ITO[idx], "width": 3}, + marker={"color": IMPRINT[idx], "size": 12}, + line={"color": IMPRINT[idx], "width": 3}, name=species, showlegend=True, ) @@ -179,7 +179,7 @@ def branch_color(node_id): "x": lx, "y": ly, "text": labels[leaf], - "font": {"size": 10, "color": OKABE_ITO[y[leaf]]}, + "font": {"size": 10, "color": IMPRINT[y[leaf]]}, "showarrow": False, "xanchor": xanchor, "yanchor": yanchor, diff --git a/plots/diagnostic-regression-panel/implementations/python/plotly.py b/plots/diagnostic-regression-panel/implementations/python/plotly.py index a3fb7e97bc..140376a4b4 100644 --- a/plots/diagnostic-regression-panel/implementations/python/plotly.py +++ b/plots/diagnostic-regression-panel/implementations/python/plotly.py @@ -21,8 +21,8 @@ INK_MUTED = "#6B6A63" if THEME == "light" else "#A8A79F" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 — scatter points -C2 = "#D55E00" # Okabe-Ito position 2 — LOWESS smoother lines -C4 = "#CC79A7" # Okabe-Ito position 4 — Cook's distance contours +C2 = "#C475FD" # Okabe-Ito position 2 — LOWESS smoother lines +C4 = "#BD8233" # Okabe-Ito position 4 — Cook's distance contours # Data — apartment rental price regression with synthetic data np.random.seed(42) diff --git a/plots/donut-nested/implementations/python/plotly.py b/plots/donut-nested/implementations/python/plotly.py index cccf99d308..a59eb09de9 100644 --- a/plots/donut-nested/implementations/python/plotly.py +++ b/plots/donut-nested/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito categorical palette (canonical order, positions 1-4 for inner ring) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] def lighten_hex(hex_color, factor=0.4): @@ -33,7 +33,7 @@ def lighten_hex(hex_color, factor=0.4): # Data - Company budget allocation by department and expense category departments = ["Engineering", "Marketing", "Sales", "Operations"] dept_values = [45, 25, 18, 12] # Millions -dept_colors = OKABE_ITO +dept_colors = IMPRINT # Child categories (outer ring) with consistent color families (lighter shades) categories = [ diff --git a/plots/dot-matrix-proportional/implementations/python/plotly.py b/plots/dot-matrix-proportional/implementations/python/plotly.py index 68f275cf98..aa6f2ee983 100644 --- a/plots/dot-matrix-proportional/implementations/python/plotly.py +++ b/plots/dot-matrix-proportional/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Data: city commute survey, 100 respondents categories = ["Public Transit", "Car", "Cycling", "Work from Home"] counts = [42, 31, 15, 12] -colors = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +colors = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] total = sum(counts) # 100 grid_cols = 10 grid_rows = total // grid_cols # 10 diff --git a/plots/drawdown-basic/implementations/python/plotly.py b/plots/drawdown-basic/implementations/python/plotly.py index 71bbf5165c..25d29d4002 100644 --- a/plots/drawdown-basic/implementations/python/plotly.py +++ b/plots/drawdown-basic/implementations/python/plotly.py @@ -22,9 +22,9 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" -LOSS_RED = "#B71D27" # anyplot palette position 3 — semantic: loss/drawdown +LOSS_RED = "#AE3030" # anyplot palette position 3 — semantic: loss/drawdown RECOVERY_GREEN = "#009E73" # anyplot palette position 1 — semantic: recovery/new high # Data — simulated stock price with realistic volatility @@ -70,7 +70,7 @@ x=dates, y=drawdown, fill="tozeroy", - fillcolor="rgba(183,29,39,0.30)", + fillcolor="rgba(174, 48, 48, 0.30)", line=dict(color=LOSS_RED, width=2), name="Drawdown", hovertemplate="Date: %{x|%Y-%m-%d}
Drawdown: %{y:.2f}%", diff --git a/plots/dumbbell-basic/implementations/python/plotly.py b/plots/dumbbell-basic/implementations/python/plotly.py index 738eadd920..eddc52e331 100644 --- a/plots/dumbbell-basic/implementations/python/plotly.py +++ b/plots/dumbbell-basic/implementations/python/plotly.py @@ -19,7 +19,7 @@ # Okabe-Ito palette (theme-independent data colors) BEFORE_COLOR = "#009E73" # position 1 — first categorical series -AFTER_COLOR = "#D55E00" # position 2 — second series +AFTER_COLOR = "#C475FD" # position 2 — second series # Data — Employee satisfaction scores before and after policy changes. # Deterministic, hand-picked values (no RNG): one department (Legal) shows a diff --git a/plots/elbow-curve/implementations/python/plotly.py b/plots/elbow-curve/implementations/python/plotly.py index 008105f478..3b8eb9355c 100644 --- a/plots/elbow-curve/implementations/python/plotly.py +++ b/plots/elbow-curve/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -ACCENT = "#D55E00" +ACCENT = "#C475FD" # Data - simulate K-means inertia values for k=1 to k=12 np.random.seed(42) diff --git a/plots/frequency-polygon-basic/implementations/python/plotly.py b/plots/frequency-polygon-basic/implementations/python/plotly.py index e3b91f8959..9800daf700 100644 --- a/plots/frequency-polygon-basic/implementations/python/plotly.py +++ b/plots/frequency-polygon-basic/implementations/python/plotly.py @@ -16,12 +16,12 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.2)" if THEME == "light" else "rgba(240,239,232,0.2)" +GRID = "rgba(26, 26, 23, 0.2)" if THEME == "light" else "rgba(240, 239, 232, 0.2)" # Okabe-Ito palette BRAND = "#009E73" # Okabe-Ito position 1 — ALWAYS first series -OKABE_VERMILLION = "#D55E00" # Okabe-Ito position 2 -OKABE_BLUE = "#0072B2" # Okabe-Ito position 3 +OKABE_VERMILLION = "#C475FD" # Okabe-Ito position 2 +OKABE_BLUE = "#4467A3" # Okabe-Ito position 3 # Data - Reaction times (ms) for three experimental conditions np.random.seed(42) @@ -76,7 +76,7 @@ line={"color": OKABE_VERMILLION, "width": 4}, marker={"size": 10, "color": OKABE_VERMILLION}, fill="tozeroy", - fillcolor="rgba(213, 94, 0, 0.2)", + fillcolor="rgba(196, 117, 253, 0.2)", ) ) @@ -89,7 +89,7 @@ line={"color": OKABE_BLUE, "width": 4, "dash": "dash"}, marker={"size": 10, "color": OKABE_BLUE}, fill="tozeroy", - fillcolor="rgba(0, 114, 178, 0.2)", + fillcolor="rgba(68, 103, 163, 0.2)", ) ) diff --git a/plots/frontier-efficient/implementations/python/plotly.py b/plots/frontier-efficient/implementations/python/plotly.py index cc8b4e6567..f5ebae0b17 100644 --- a/plots/frontier-efficient/implementations/python/plotly.py +++ b/plots/frontier-efficient/implementations/python/plotly.py @@ -25,9 +25,9 @@ # Okabe-Ito palette BRAND = "#009E73" -SECONDARY = "#D55E00" -TERTIARY = "#0072B2" -ACCENT_1 = "#CC79A7" +SECONDARY = "#C475FD" +TERTIARY = "#4467A3" +ACCENT_1 = "#BD8233" # Data - Generate random portfolios and efficient frontier np.random.seed(42) diff --git a/plots/funnel-basic/implementations/python/plotly.py b/plots/funnel-basic/implementations/python/plotly.py index ab81b728ae..40320a496c 100644 --- a/plots/funnel-basic/implementations/python/plotly.py +++ b/plots/funnel-basic/implementations/python/plotly.py @@ -17,7 +17,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito categorical palette (first series is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data - Sales funnel example stages = ["Awareness", "Interest", "Consideration", "Intent", "Purchase"] @@ -31,7 +31,7 @@ textposition="inside", textinfo="value+percent initial", textfont={"size": 22, "color": "#FAF8F1"}, - marker={"color": OKABE_ITO, "line": {"width": 2, "color": PAGE_BG}}, + marker={"color": IMPRINT, "line": {"width": 2, "color": PAGE_BG}}, connector={"line": {"color": INK_SOFT, "width": 1, "dash": "dot"}}, ) ) diff --git a/plots/gain-curve/implementations/python/plotly.py b/plots/gain-curve/implementations/python/plotly.py index 7f1e35c446..12be4e54d3 100644 --- a/plots/gain-curve/implementations/python/plotly.py +++ b/plots/gain-curve/implementations/python/plotly.py @@ -21,7 +21,7 @@ # Okabe-Ito palette BRAND = "#009E73" # First series — always BASELINE = "#888888" # Neutral for reference -PERFECT = "#E69F00" # Orange for perfect model +PERFECT = "#4467A3" # imprint blue — neutral reference for perfect model (red is reserved for semantic bad) # Data - Customer response model evaluation np.random.seed(42) diff --git a/plots/gantt-basic/implementations/python/plotly.py b/plots/gantt-basic/implementations/python/plotly.py index 37f5cb45c0..2ca04aecbe 100644 --- a/plots/gantt-basic/implementations/python/plotly.py +++ b/plots/gantt-basic/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.15)" if THEME == "light" else "rgba(240,239,232,0.15)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data - Software Development Project Timeline tasks = [ @@ -47,11 +47,11 @@ # Color map using Okabe-Ito palette color_map = { - "Planning": OKABE_ITO[0], - "Design": OKABE_ITO[1], - "Development": OKABE_ITO[2], - "Testing": OKABE_ITO[3], - "Deployment": OKABE_ITO[4], + "Planning": IMPRINT[0], + "Design": IMPRINT[1], + "Development": IMPRINT[2], + "Testing": IMPRINT[3], + "Deployment": IMPRINT[4], } # Create Gantt chart using timeline diff --git a/plots/gauge-basic/implementations/python/plotly.py b/plots/gauge-basic/implementations/python/plotly.py index a6b0fa5c41..92a253f9de 100644 --- a/plots/gauge-basic/implementations/python/plotly.py +++ b/plots/gauge-basic/implementations/python/plotly.py @@ -18,9 +18,9 @@ INK_MUTED = "#6B6A63" if THEME == "light" else "#A8A79F" # Okabe-Ito colorblind-safe stand-ins for the red/amber/green convention -ZONE_LOW = "#D55E00" # vermillion (bad) -ZONE_MID = "#E69F00" # orange (caution) -ZONE_HIGH = "#009E73" # bluish green — Okabe-Ito brand (good) +ZONE_LOW = "#AE3030" # imprint red — bad +ZONE_MID = "#DDCC77" # imprint amber — caution +ZONE_HIGH = "#009E73" # imprint green — good # Data — Sales target achievement for the quarter value = 72 diff --git a/plots/hierarchy-toggle-view/implementations/python/plotly.py b/plots/hierarchy-toggle-view/implementations/python/plotly.py index bb9bc13628..5d63225c3c 100644 --- a/plots/hierarchy-toggle-view/implementations/python/plotly.py +++ b/plots/hierarchy-toggle-view/implementations/python/plotly.py @@ -52,7 +52,7 @@ values.append(team_budget) # Okabe-Ito palette for departments (positions 1–4) -dept_colors = {"Engineering": "#009E73", "Marketing": "#D55E00", "Sales": "#0072B2", "Operations": "#CC79A7"} +dept_colors = {"Engineering": "#009E73", "Marketing": "#C475FD", "Sales": "#4467A3", "Operations": "#BD8233"} colors = [] for i, label in enumerate(labels): diff --git a/plots/histogram-density/implementations/python/plotly.py b/plots/histogram-density/implementations/python/plotly.py index c5a8867f7c..7a451a36d2 100644 --- a/plots/histogram-density/implementations/python/plotly.py +++ b/plots/histogram-density/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 -OKABE_ITO_2 = "#D55E00" # Okabe-Ito position 2 for KDE curve +OKABE_ITO_2 = "#C475FD" # Okabe-Ito position 2 for KDE curve # Data - simulated test scores with a more pronounced bimodal distribution np.random.seed(42) diff --git a/plots/histogram-kde/implementations/python/plotly.py b/plots/histogram-kde/implementations/python/plotly.py index 04e3f2e10a..d9e9028e03 100644 --- a/plots/histogram-kde/implementations/python/plotly.py +++ b/plots/histogram-kde/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 — first series -KDE_COLOR = "#D55E00" # Okabe-Ito position 2 +KDE_COLOR = "#C475FD" # Okabe-Ito position 2 # Data - Stock returns simulation with realistic distribution np.random.seed(42) diff --git a/plots/histogram-overlapping/implementations/python/plotly.py b/plots/histogram-overlapping/implementations/python/plotly.py index 43918277b6..f9afd7911a 100644 --- a/plots/histogram-overlapping/implementations/python/plotly.py +++ b/plots/histogram-overlapping/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00"] +IMPRINT = ["#009E73", "#C475FD"] # Data - heights by gender (realistic scenario showing overlapping distributions) np.random.seed(42) @@ -32,7 +32,7 @@ go.Histogram( x=male_heights, name="Male", - marker=dict(color=OKABE_ITO[0], line=dict(color=INK_SOFT, width=1)), + marker=dict(color=IMPRINT[0], line=dict(color=INK_SOFT, width=1)), opacity=0.5, xbins=dict(size=3), ) @@ -42,7 +42,7 @@ go.Histogram( x=female_heights, name="Female", - marker=dict(color=OKABE_ITO[1], line=dict(color=INK_SOFT, width=1)), + marker=dict(color=IMPRINT[1], line=dict(color=INK_SOFT, width=1)), opacity=0.5, xbins=dict(size=3), ) diff --git a/plots/histogram-returns-distribution/implementations/python/plotly.py b/plots/histogram-returns-distribution/implementations/python/plotly.py index b86c4ac88b..f3e9015036 100644 --- a/plots/histogram-returns-distribution/implementations/python/plotly.py +++ b/plots/histogram-returns-distribution/implementations/python/plotly.py @@ -21,8 +21,8 @@ # Okabe-Ito palette BRAND = "#009E73" # position 1 — normal return bars -VERMILLION = "#D55E00" # position 2 — tail region bars -BLUE = "#0072B2" # position 3 — normal distribution curve +VERMILLION = "#C475FD" # position 2 — tail region bars +BLUE = "#4467A3" # position 3 — normal distribution curve # Data - Simulated daily stock returns (504 trading days / 2 years) np.random.seed(42) diff --git a/plots/histogram-stacked/implementations/python/plotly.py b/plots/histogram-stacked/implementations/python/plotly.py index 34755875a6..4fd13657b1 100644 --- a/plots/histogram-stacked/implementations/python/plotly.py +++ b/plots/histogram-stacked/implementations/python/plotly.py @@ -27,7 +27,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is ALWAYS #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - Product weights from three production lines np.random.seed(42) @@ -59,7 +59,7 @@ x=bin_centers, y=hist_a, name="Line A", - marker_color=OKABE_ITO[0], + marker_color=IMPRINT[0], width=bin_width * 0.9, hovertemplate="Line A
Weight: %{x:.1f}g
Count: %{y}", ) @@ -70,7 +70,7 @@ x=bin_centers, y=hist_b, name="Line B", - marker_color=OKABE_ITO[1], + marker_color=IMPRINT[1], width=bin_width * 0.9, hovertemplate="Line B
Weight: %{x:.1f}g
Count: %{y}", ) @@ -81,7 +81,7 @@ x=bin_centers, y=hist_c, name="Line C", - marker_color=OKABE_ITO[2], + marker_color=IMPRINT[2], width=bin_width * 0.9, hovertemplate="Line C
Weight: %{x:.1f}g
Count: %{y}", ) diff --git a/plots/hive-basic/implementations/python/plotly.py b/plots/hive-basic/implementations/python/plotly.py index 72c9e2b85b..2869253bb3 100644 --- a/plots/hive-basic/implementations/python/plotly.py +++ b/plots/hive-basic/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito for the 3 axes (positions 1, 2, 3) -AXIS_COLORS = {"core": "#009E73", "utility": "#D55E00", "interface": "#0072B2"} +AXIS_COLORS = {"core": "#009E73", "utility": "#C475FD", "interface": "#4467A3"} # Data: Software module dependency network np.random.seed(42) diff --git a/plots/icicle-basic/implementations/python/plotly.py b/plots/icicle-basic/implementations/python/plotly.py index 14c55406c8..b54d946bf8 100644 --- a/plots/icicle-basic/implementations/python/plotly.py +++ b/plots/icicle-basic/implementations/python/plotly.py @@ -18,7 +18,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data - File system hierarchy data = { @@ -77,11 +77,11 @@ def get_node_level(node, df): if level == 0: colors.append(BRAND) elif level == 1: - colors.append(OKABE_ITO[1]) + colors.append(IMPRINT[1]) elif level == 2: - colors.append(OKABE_ITO[2]) + colors.append(IMPRINT[2]) else: - colors.append(OKABE_ITO[3]) + colors.append(IMPRINT[3]) # Create icicle chart fig = go.Figure( diff --git a/plots/indicator-bollinger/implementations/python/plotly.py b/plots/indicator-bollinger/implementations/python/plotly.py index 81318e6e30..0104f3a0f6 100644 --- a/plots/indicator-bollinger/implementations/python/plotly.py +++ b/plots/indicator-bollinger/implementations/python/plotly.py @@ -31,13 +31,13 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 — close price -OKABE_ITO = [ - "#D55E00", # position 2 — upper/lower bands - "#0072B2", # position 3 — SMA - "#CC79A7", - "#E69F00", - "#56B4E9", - "#F0E442", +IMPRINT = [ + "#C475FD", # position 2 — upper/lower bands + "#4467A3", # position 3 — SMA + "#BD8233", + "#AE3030", + "#2ABCCD", + "#954477", ] # Data - Generate realistic stock price data with Bollinger Bands @@ -78,7 +78,7 @@ mode="lines", line={"width": 0}, fill="tonexty", - fillcolor=f"rgba({int(OKABE_ITO[0][1:3], 16)}, {int(OKABE_ITO[0][3:5], 16)}, {int(OKABE_ITO[0][5:7], 16)}, 0.15)", + fillcolor=f"rgba({int(IMPRINT[0][1:3], 16)}, {int(IMPRINT[0][3:5], 16)}, {int(IMPRINT[0][5:7], 16)}, 0.15)", name="Bollinger Bands (2σ)", hoverinfo="skip", ) @@ -90,7 +90,7 @@ x=df["date"], y=df["upper_band"], mode="lines", - line={"color": OKABE_ITO[0], "width": 2, "dash": "solid"}, + line={"color": IMPRINT[0], "width": 2, "dash": "solid"}, name="Upper Band (+2σ)", hovertemplate="Upper: $%{y:.2f}", ) @@ -102,7 +102,7 @@ x=df["date"], y=df["lower_band"], mode="lines", - line={"color": OKABE_ITO[0], "width": 2, "dash": "solid"}, + line={"color": IMPRINT[0], "width": 2, "dash": "solid"}, name="Lower Band (-2σ)", hovertemplate="Lower: $%{y:.2f}", ) @@ -114,7 +114,7 @@ x=df["date"], y=df["sma"], mode="lines", - line={"color": OKABE_ITO[1], "width": 3, "dash": "dash"}, + line={"color": IMPRINT[1], "width": 3, "dash": "dash"}, name="20-day SMA", hovertemplate="SMA: $%{y:.2f}", ) diff --git a/plots/indicator-ema/implementations/python/plotly.py b/plots/indicator-ema/implementations/python/plotly.py index bc51ff1e2f..d32a498f7c 100644 --- a/plots/indicator-ema/implementations/python/plotly.py +++ b/plots/indicator-ema/implementations/python/plotly.py @@ -21,10 +21,10 @@ # Okabe-Ito palette — positions 1-5 in canonical order BRAND = "#009E73" # price line (first series) -EMA_SHORT = "#D55E00" # EMA 12 -EMA_LONG = "#0072B2" # EMA 26 -GOLDEN_CLR = "#CC79A7" # golden cross marker -DEATH_CLR = "#E69F00" # death cross marker +EMA_SHORT = "#C475FD" # EMA 12 +EMA_LONG = "#4467A3" # EMA 26 +GOLDEN_CLR = "#DDCC77" # imprint amber — golden cross marker +DEATH_CLR = "#AE3030" # death cross marker # Data — realistic stock price with trend, consolidation, and recovery np.random.seed(42) diff --git a/plots/indicator-macd/implementations/python/plotly.py b/plots/indicator-macd/implementations/python/plotly.py index f1e9b30791..b0de1fec78 100644 --- a/plots/indicator-macd/implementations/python/plotly.py +++ b/plots/indicator-macd/implementations/python/plotly.py @@ -22,7 +22,7 @@ # Okabe-Ito palette BRAND = "#009E73" # MACD -SIGNAL_COLOR = "#D55E00" # Signal line +SIGNAL_COLOR = "#BD8233" # imprint ochre — signal line (categorical contrast) # Data - Generate realistic stock price data and calculate MACD np.random.seed(42) @@ -52,7 +52,7 @@ # Create histogram colors using diverging approach hist_positive = histogram >= 0 hist_colors = [ - "#0072B2" if val else "#CC79A7" # Blue for positive, purple for negative + "#4467A3" if val else "#BD8233" # Blue for positive, purple for negative for val in hist_positive ] diff --git a/plots/indicator-rsi/implementations/python/plotly.py b/plots/indicator-rsi/implementations/python/plotly.py index 25eb9c1618..63196f49ae 100644 --- a/plots/indicator-rsi/implementations/python/plotly.py +++ b/plots/indicator-rsi/implementations/python/plotly.py @@ -17,7 +17,7 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" BRAND = "#009E73" # Generate sample stock data and calculate RSI @@ -59,7 +59,7 @@ fill="tonexty", mode="lines", line={"width": 0}, - fillcolor="rgba(213, 94, 0, 0.15)", + fillcolor="rgba(196, 117, 253, 0.15)", name="Overbought Zone (70-100)", ) ) @@ -86,9 +86,9 @@ fig.add_trace(go.Scatter(x=dates, y=rsi, mode="lines", name="RSI (14)", line={"color": BRAND, "width": 3})) # Add reference lines -fig.add_hline(y=70, line_dash="dash", line_color="#D55E00", line_width=2) +fig.add_hline(y=70, line_dash="dash", line_color="#AE3030", line_width=2) # imprint red overbought fig.add_hline(y=50, line_dash="dot", line_color=INK_SOFT, line_width=1.5) -fig.add_hline(y=30, line_dash="dash", line_color="#0072B2", line_width=2) +fig.add_hline(y=30, line_dash="dash", line_color="#4467A3", line_width=2) # Annotations for threshold lines fig.add_annotation( @@ -98,7 +98,7 @@ showarrow=False, xanchor="left", xshift=10, - font={"size": 16, "color": "#D55E00"}, + font={"size": 16, "color": "#AE3030"}, ) fig.add_annotation( x=dates[-1], @@ -116,7 +116,7 @@ showarrow=False, xanchor="left", xshift=10, - font={"size": 16, "color": "#0072B2"}, + font={"size": 16, "color": "#4467A3"}, ) # Layout diff --git a/plots/indicator-sma/implementations/python/plotly.py b/plots/indicator-sma/implementations/python/plotly.py index db3a253620..5620a74f35 100644 --- a/plots/indicator-sma/implementations/python/plotly.py +++ b/plots/indicator-sma/implementations/python/plotly.py @@ -21,9 +21,9 @@ # Okabe-Ito palette — positions 1–4 PRICE_COLOR = "#009E73" # position 1 — first series (close price) -SMA20_COLOR = "#D55E00" # position 2 -SMA50_COLOR = "#0072B2" # position 3 -SMA200_COLOR = "#CC79A7" # position 4 +SMA20_COLOR = "#C475FD" # position 2 +SMA50_COLOR = "#4467A3" # position 3 +SMA200_COLOR = "#BD8233" # position 4 # Data np.random.seed(42) diff --git a/plots/kagi-basic/implementations/python/plotly.py b/plots/kagi-basic/implementations/python/plotly.py index 75d0853514..2511bc866a 100644 --- a/plots/kagi-basic/implementations/python/plotly.py +++ b/plots/kagi-basic/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito palette: green for yang (bullish), vermillion for yin (bearish) YANG_COLOR = "#009E73" # Okabe-Ito position 1 - green -YIN_COLOR = "#D55E00" # Okabe-Ito position 2 - vermillion +YIN_COLOR = "#AE3030" # imprint red — bearish # Generate sample price data designed to demonstrate multiple yang/yin transitions np.random.seed(42) diff --git a/plots/learning-curve-basic/implementations/python/plotly.py b/plots/learning-curve-basic/implementations/python/plotly.py index ffaaab9c99..ec11ccef69 100644 --- a/plots/learning-curve-basic/implementations/python/plotly.py +++ b/plots/learning-curve-basic/implementations/python/plotly.py @@ -31,7 +31,7 @@ # Okabe-Ito palette (first series always #009E73) TRAIN_COLOR = "#009E73" # bluish green -VAL_COLOR = "#D55E00" # vermillion +VAL_COLOR = "#C475FD" # vermillion # Data - Simulate learning curve data from cross-validation np.random.seed(42) diff --git a/plots/lift-curve/implementations/python/plotly.py b/plots/lift-curve/implementations/python/plotly.py index 8ccaf6d8a2..5922313e57 100644 --- a/plots/lift-curve/implementations/python/plotly.py +++ b/plots/lift-curve/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito palette BRAND = "#009E73" # First series, always -ACCENT = "#D55E00" # Second series +ACCENT = "#C475FD" # Second series # Data: Simulate customer response model predictions np.random.seed(42) diff --git a/plots/line-3d-trajectory/implementations/python/plotly.py b/plots/line-3d-trajectory/implementations/python/plotly.py index 431cc32f77..0f66ace2ec 100644 --- a/plots/line-3d-trajectory/implementations/python/plotly.py +++ b/plots/line-3d-trajectory/implementations/python/plotly.py @@ -25,7 +25,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data: Multiple 3D helix trajectories with different periods and amplitudes np.random.seed(42) @@ -39,7 +39,7 @@ x1 = 5 * np.cos(t1) y1 = 5 * np.sin(t1) z1 = 3 * t1 / (8 * np.pi) -trajectories.append((x1, y1, z1, OKABE_ITO[0])) +trajectories.append((x1, y1, z1, IMPRINT[0])) labels.append("Standard Helix") # Helix 2: Compressed helix (faster rise, tighter spiral) @@ -47,7 +47,7 @@ x2 = 3.5 * np.cos(2 * t2) y2 = 3.5 * np.sin(2 * t2) z2 = 5 * t2 / (6 * np.pi) -trajectories.append((x2, y2, z2, OKABE_ITO[1])) +trajectories.append((x2, y2, z2, IMPRINT[1])) labels.append("Compressed Helix") # Helix 3: Expanding helix (amplitude increases with height) @@ -56,7 +56,7 @@ x3 = amplitude * np.cos(t3) y3 = amplitude * np.sin(t3) z3 = 6 * t3 / (4 * np.pi) -trajectories.append((x3, y3, z3, OKABE_ITO[2])) +trajectories.append((x3, y3, z3, IMPRINT[2])) labels.append("Expanding Helix") # Create 3D line plot with multiple trajectories diff --git a/plots/line-loss-training/implementations/python/plotly.py b/plots/line-loss-training/implementations/python/plotly.py index 2477bc3f90..9625ca796e 100644 --- a/plots/line-loss-training/implementations/python/plotly.py +++ b/plots/line-loss-training/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito palette TRAIN_COLOR = "#009E73" # Position 1 - bluish green (brand) -VAL_COLOR = "#D55E00" # Position 2 - vermillion +VAL_COLOR = "#C475FD" # Position 2 - vermillion # Data - Simulated neural network training with different trajectory np.random.seed(42) diff --git a/plots/line-markers/implementations/python/plotly.py b/plots/line-markers/implementations/python/plotly.py index 4a6df00637..4d4f5d2257 100644 --- a/plots/line-markers/implementations/python/plotly.py +++ b/plots/line-markers/implementations/python/plotly.py @@ -20,8 +20,8 @@ # Okabe-Ito palette BRAND = "#009E73" -COLOR_2 = "#D55E00" -COLOR_3 = "#0072B2" +COLOR_2 = "#C475FD" +COLOR_3 = "#4467A3" # Data - experimental temperature readings over time np.random.seed(42) diff --git a/plots/line-multi/implementations/python/plotly.py b/plots/line-multi/implementations/python/plotly.py index 14a6f7cd80..688b72f262 100644 --- a/plots/line-multi/implementations/python/plotly.py +++ b/plots/line-multi/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (positions 1-4 for 4 series) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Monthly sales (units) for 4 product lines over 12 months np.random.seed(42) @@ -41,7 +41,7 @@ y=electronics, name="Electronics", mode="lines+markers", - line=dict(color=OKABE_ITO[0], width=4), + line=dict(color=IMPRINT[0], width=4), marker=dict(size=12, symbol="circle"), ) ) @@ -52,7 +52,7 @@ y=clothing, name="Clothing", mode="lines+markers", - line=dict(color=OKABE_ITO[1], width=4), + line=dict(color=IMPRINT[1], width=4), marker=dict(size=12, symbol="square"), ) ) @@ -63,7 +63,7 @@ y=home_garden, name="Home & Garden", mode="lines+markers", - line=dict(color=OKABE_ITO[2], width=4, dash="dash"), + line=dict(color=IMPRINT[2], width=4, dash="dash"), marker=dict(size=12, symbol="diamond"), ) ) @@ -74,7 +74,7 @@ y=sports, name="Sports", mode="lines+markers", - line=dict(color=OKABE_ITO[3], width=4, dash="dot"), + line=dict(color=IMPRINT[3], width=4, dash="dot"), marker=dict(size=12, symbol="triangle-up"), ) ) diff --git a/plots/line-stock-comparison/implementations/python/plotly.py b/plots/line-stock-comparison/implementations/python/plotly.py index 8ebb3c9647..01b5490f38 100644 --- a/plots/line-stock-comparison/implementations/python/plotly.py +++ b/plots/line-stock-comparison/implementations/python/plotly.py @@ -21,7 +21,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" SELECTOR_ACTIVE = "rgba(26,26,23,0.12)" if THEME == "light" else "rgba(240,239,232,0.12)" -ANYPLOT_PALETTE = ["#009E73", "#9418DB", "#B71D27", "#16B8F3"] +IMPRINT = ["#009E73", "#C475FD", "#AE3030", "#4467A3"] # Data - Generate synthetic stock price data for 4 companies np.random.seed(42) @@ -58,7 +58,7 @@ y=df_rebased[symbol], mode="lines", name=symbol, - line={"width": 2.5, "color": ANYPLOT_PALETTE[i]}, + line={"width": 2.5, "color": IMPRINT[i]}, hovertemplate=f"{symbol}
Date: %{{x|%Y-%m-%d}}
Value: %{{y:.1f}}", ) ) @@ -87,7 +87,7 @@ showarrow=False, xanchor="left", yanchor="middle", - font={"size": 9, "color": ANYPLOT_PALETTE[i]}, + font={"size": 9, "color": IMPRINT[i]}, ) # Layout diff --git a/plots/line-styled/implementations/python/plotly.py b/plots/line-styled/implementations/python/plotly.py index 00fa32ff23..53a01370d7 100644 --- a/plots/line-styled/implementations/python/plotly.py +++ b/plots/line-styled/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.15)" if THEME == "light" else "rgba(240,239,232,0.15)" # Okabe-Ito colors (position 1 is always brand green) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Temperature readings from different environments over 24 hours np.random.seed(42) @@ -41,7 +41,7 @@ y=sensor_a, mode="lines", name="Outdoor Sensor", - line=dict(dash="solid", width=4, color=OKABE_ITO[0]), + line=dict(dash="solid", width=4, color=IMPRINT[0]), hovertemplate="Outdoor
Hour: %{x}
Temp: %{y:.1f}°C", ) ) @@ -52,7 +52,7 @@ y=sensor_b, mode="lines", name="Indoor Sensor", - line=dict(dash="dash", width=4, color=OKABE_ITO[1]), + line=dict(dash="dash", width=4, color=IMPRINT[1]), hovertemplate="Indoor
Hour: %{x}
Temp: %{y:.1f}°C", ) ) @@ -63,7 +63,7 @@ y=sensor_c, mode="lines", name="Greenhouse Sensor", - line=dict(dash="dot", width=4, color=OKABE_ITO[2]), + line=dict(dash="dot", width=4, color=IMPRINT[2]), hovertemplate="Greenhouse
Hour: %{x}
Temp: %{y:.1f}°C", ) ) @@ -74,7 +74,7 @@ y=sensor_d, mode="lines", name="Storage Sensor", - line=dict(dash="dashdot", width=4, color=OKABE_ITO[3]), + line=dict(dash="dashdot", width=4, color=IMPRINT[3]), hovertemplate="Storage
Hour: %{x}
Temp: %{y:.1f}°C", ) ) diff --git a/plots/line-timeseries-rolling/implementations/python/plotly.py b/plots/line-timeseries-rolling/implementations/python/plotly.py index 73229904cf..f5400179ac 100644 --- a/plots/line-timeseries-rolling/implementations/python/plotly.py +++ b/plots/line-timeseries-rolling/implementations/python/plotly.py @@ -21,7 +21,7 @@ # Okabe-Ito palette BRAND = "#009E73" # Raw data (first series) -ACCENT = "#D55E00" # Rolling average +ACCENT = "#C475FD" # Rolling average # Data - Daily temperature readings with noise np.random.seed(42) diff --git a/plots/logistic-regression/implementations/python/plotly.py b/plots/logistic-regression/implementations/python/plotly.py index e43888010e..32a6ac8f47 100644 --- a/plots/logistic-regression/implementations/python/plotly.py +++ b/plots/logistic-regression/implementations/python/plotly.py @@ -25,7 +25,7 @@ # Okabe-Ito palette BRAND = "#009E73" # First series - bluish green -ACCENT = "#D55E00" # Second series - vermillion +ACCENT = "#C475FD" # Second series - vermillion # Data - medical biomarker vs disease diagnosis np.random.seed(42) diff --git a/plots/lollipop-grouped/implementations/python/plotly.py b/plots/lollipop-grouped/implementations/python/plotly.py index d268bfc35d..7b71e235cc 100644 --- a/plots/lollipop-grouped/implementations/python/plotly.py +++ b/plots/lollipop-grouped/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - Quarterly revenue by product line across regions (in millions $) np.random.seed(42) @@ -44,7 +44,7 @@ x_base = np.arange(n_categories) # Add stems and markers for each series -for i, (series, color) in enumerate(zip(series_names, OKABE_ITO, strict=False)): +for i, (series, color) in enumerate(zip(series_names, IMPRINT, strict=False)): # Calculate x positions with offset for grouping offset = (i - (n_series - 1) / 2) * bar_width x_positions = x_base + offset diff --git a/plots/manhattan-gwas/implementations/python/plotly.py b/plots/manhattan-gwas/implementations/python/plotly.py index b8177060e0..0f9db4f719 100644 --- a/plots/manhattan-gwas/implementations/python/plotly.py +++ b/plots/manhattan-gwas/implementations/python/plotly.py @@ -30,19 +30,19 @@ GRID = "rgba(26,26,23,0.15)" if THEME == "light" else "rgba(240,239,232,0.15)" # Okabe-Ito palette -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple - "#E69F00", # orange - "#56B4E9", # sky blue - "#F0E442", # yellow + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple + "#AE3030", # orange + "#2ABCCD", # sky blue + "#954477", # yellow ] # Threshold line colors (theme-adaptive) THRESHOLD_COLOR = INK_MUTED -HIGHLIGHT_COLOR = OKABE_ITO[1] # vermillion for significant SNPs +HIGHLIGHT_COLOR = IMPRINT[1] # vermillion for significant SNPs # Data - Simulated GWAS results np.random.seed(42) @@ -119,7 +119,7 @@ # Alternating chromosome colors (Okabe-Ito positions 1 and 2) def get_chr_color(chrom_num): - return OKABE_ITO[0] if int(chrom_num) % 2 == 1 else OKABE_ITO[1] + return IMPRINT[0] if int(chrom_num) % 2 == 1 else IMPRINT[1] # Create figure diff --git a/plots/map-drilldown-geographic/implementations/python/plotly.py b/plots/map-drilldown-geographic/implementations/python/plotly.py index e28400d4b5..a85b686a2b 100644 --- a/plots/map-drilldown-geographic/implementations/python/plotly.py +++ b/plots/map-drilldown-geographic/implementations/python/plotly.py @@ -271,7 +271,7 @@ ), ( sorted_by_total[-1], - "#B71D27", + "#AE3030", "triangle-down", 12, f"▼ Low: {us_states_data[sorted_by_total[-1]]['abbrev']} ${state_totals[sorted_by_total[-1]]:,}K", diff --git a/plots/map-marker-clustered/implementations/python/plotly.py b/plots/map-marker-clustered/implementations/python/plotly.py index 7d4a7e0336..b311876dec 100644 --- a/plots/map-marker-clustered/implementations/python/plotly.py +++ b/plots/map-marker-clustered/implementations/python/plotly.py @@ -19,7 +19,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # anyplot palette — canonical order for categorical series -ANYPLOT_PALETTE = ["#009E73", "#9418DB", "#B71D27", "#16B8F3"] +IMPRINT = ["#009E73", "#C475FD", "#AE3030", "#4467A3"] # Data - Retail store locations across North America np.random.seed(42) @@ -38,7 +38,7 @@ } categories = ["Electronics", "Grocery", "Clothing", "Hardware"] -category_colors = {cat: ANYPLOT_PALETTE[i] for i, cat in enumerate(categories)} +category_colors = {cat: IMPRINT[i] for i, cat in enumerate(categories)} lats, lons, labels, cats = [], [], [], [] store_id = 1 diff --git a/plots/map-route-path/implementations/python/plotly.py b/plots/map-route-path/implementations/python/plotly.py index 696a9fdb6c..6b8fbdd4db 100644 --- a/plots/map-route-path/implementations/python/plotly.py +++ b/plots/map-route-path/implementations/python/plotly.py @@ -27,8 +27,8 @@ # Okabe-Ito: position 1 = start, position 2 = end, position 3 = waypoints START_COLOR = "#009E73" -END_COLOR = "#D55E00" -WAYPOINT_COLOR = "#0072B2" +END_COLOR = "#C475FD" +WAYPOINT_COLOR = "#4467A3" # Data: Appalachian Trail section through Great Smoky Mountains, Tennessee np.random.seed(42) diff --git a/plots/marimekko-basic/implementations/python/plotly.py b/plots/marimekko-basic/implementations/python/plotly.py index e658520d52..cfc24dc559 100644 --- a/plots/marimekko-basic/implementations/python/plotly.py +++ b/plots/marimekko-basic/implementations/python/plotly.py @@ -18,7 +18,7 @@ GRID = "rgba(26,26,23,0.15)" if THEME == "light" else "rgba(240,239,232,0.15)" # Okabe-Ito palette — first series always #009E73 -COLORS = ["#009E73", "#D55E00", "#0072B2"] +COLORS = ["#009E73", "#C475FD", "#4467A3"] # Data: Market share by region and product line (in millions USD) regions = ["North America", "Europe", "Asia Pacific", "Latin America"] diff --git a/plots/maze-circular/implementations/python/plotly.py b/plots/maze-circular/implementations/python/plotly.py index 9ba0a0153a..963fe71b12 100644 --- a/plots/maze-circular/implementations/python/plotly.py +++ b/plots/maze-circular/implementations/python/plotly.py @@ -173,7 +173,7 @@ y=sol_y, mode="lines", name="Show Solution", - line={"color": "#D55E00", "width": 4, "dash": "dot"}, + line={"color": "#C475FD", "width": 4, "dash": "dot"}, opacity=0.85, visible="legendonly", ) @@ -198,7 +198,7 @@ x=[0.0], y=[0.0], mode="markers", - marker={"symbol": "star", "size": 20, "color": "#F0E442", "line": {"color": ACCENT, "width": 2}}, + marker={"symbol": "star", "size": 20, "color": "#DDCC77", "line": {"color": ACCENT, "width": 2}}, showlegend=False, hoverinfo="skip", ) diff --git a/plots/mosaic-categorical/implementations/python/plotly.py b/plots/mosaic-categorical/implementations/python/plotly.py index a8a50587a4..6daf90fe8c 100644 --- a/plots/mosaic-categorical/implementations/python/plotly.py +++ b/plots/mosaic-categorical/implementations/python/plotly.py @@ -42,7 +42,7 @@ class_categories = contingency.columns.tolist() # Okabe-Ito palette: Survived = brand green (first series), Did Not Survive = vermillion -colors = {"Survived": "#009E73", "Did Not Survive": "#D55E00"} +colors = {"Survived": "#009E73", "Did Not Survive": "#C475FD"} # Gap between rectangles gap = 0.015 diff --git a/plots/network-basic/implementations/python/plotly.py b/plots/network-basic/implementations/python/plotly.py index caee1e8d5b..c7f163c83f 100644 --- a/plots/network-basic/implementations/python/plotly.py +++ b/plots/network-basic/implementations/python/plotly.py @@ -25,7 +25,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito palette — first series always #009E73 -GROUP_COLORS = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +GROUP_COLORS = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] GROUP_NAMES = ["Research", "Engineering", "Management", "Marketing"] # Data: social network with 20 people across 4 teams of varying size diff --git a/plots/network-bipartite/implementations/python/plotly.py b/plots/network-bipartite/implementations/python/plotly.py index 72d9e8058b..c8d0b5064e 100644 --- a/plots/network-bipartite/implementations/python/plotly.py +++ b/plots/network-bipartite/implementations/python/plotly.py @@ -19,7 +19,7 @@ INK_MUTED = "#6B6A63" if THEME == "light" else "#A8A79F" STUDENT_COLOR = "#009E73" # Okabe-Ito position 1 -COURSE_COLOR = "#D55E00" # Okabe-Ito position 2 +COURSE_COLOR = "#C475FD" # Okabe-Ito position 2 EDGE_COLOR = "rgba(107,106,99,0.30)" if THEME == "light" else "rgba(168,167,159,0.22)" # Data - student-course enrollment network diff --git a/plots/network-directed/implementations/python/plotly.py b/plots/network-directed/implementations/python/plotly.py index 22a358ccb9..b4cbeea14d 100644 --- a/plots/network-directed/implementations/python/plotly.py +++ b/plots/network-directed/implementations/python/plotly.py @@ -19,11 +19,11 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is #009E73) -OKABE_ITO = [ +IMPRINT = [ "#009E73", # Brand green (entry point) - "#D55E00", # Vermillion (core) - "#0072B2", # Blue (data) - "#CC79A7", # Reddish purple (helpers) + "#C475FD", # Vermillion (core) + "#4467A3", # Blue (data) + "#BD8233", # Reddish purple (helpers) ] # Data: Software module dependencies (arrows show import direction) @@ -212,7 +212,7 @@ # Add nodes by group group_names = ["Entry", "Core", "Data", "Helpers"] -for group_idx in range(len(OKABE_ITO)): +for group_idx in range(len(IMPRINT)): group_nodes = [n for n in nodes if n["group"] == group_idx] group_x = [node_x[n["id"]] for n in group_nodes] group_y = [node_y[n["id"]] for n in group_nodes] @@ -223,7 +223,7 @@ x=group_x, y=group_y, mode="markers+text", - marker=dict(size=18, color=OKABE_ITO[group_idx], line=dict(width=1.5, color=INK_SOFT)), + marker=dict(size=18, color=IMPRINT[group_idx], line=dict(width=1.5, color=INK_SOFT)), text=group_labels, textposition="middle center", textfont=dict(size=14, color=INK, family="monospace"), diff --git a/plots/network-force-directed/implementations/python/plotly.py b/plots/network-force-directed/implementations/python/plotly.py index 6c8dbcdd5c..1dfa95ec38 100644 --- a/plots/network-force-directed/implementations/python/plotly.py +++ b/plots/network-force-directed/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito categorical palette (positions 1-3) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] np.random.seed(42) @@ -135,7 +135,7 @@ mode="markers", marker={ "size": sizes, - "color": OKABE_ITO[comm_idx], + "color": IMPRINT[comm_idx], "line": {"width": 2, "color": PAGE_BG}, "opacity": 0.9, }, diff --git a/plots/network-hierarchical/implementations/python/plotly.py b/plots/network-hierarchical/implementations/python/plotly.py index 1f19befc2d..500b0544cc 100644 --- a/plots/network-hierarchical/implementations/python/plotly.py +++ b/plots/network-hierarchical/implementations/python/plotly.py @@ -19,9 +19,9 @@ # Okabe-Ito palette for hierarchy levels (position 1 is brand, then positions 2-4) LEVEL_COLORS = { 0: "#009E73", # Position 1 - brand green (CEO) - 1: "#D55E00", # Position 2 - vermillion (VPs) - 2: "#0072B2", # Position 3 - blue (Directors) - 3: "#CC79A7", # Position 4 - reddish purple (Leads) + 1: "#C475FD", # Position 2 - vermillion (VPs) + 2: "#4467A3", # Position 3 - blue (Directors) + 3: "#BD8233", # Position 4 - reddish purple (Leads) } # Data: Organizational chart with 22 employees across 4 levels - asymmetric structure diff --git a/plots/network-transport-static/implementations/python/plotly.py b/plots/network-transport-static/implementations/python/plotly.py index 2ab001ffdd..6d70c09a6e 100644 --- a/plots/network-transport-static/implementations/python/plotly.py +++ b/plots/network-transport-static/implementations/python/plotly.py @@ -19,10 +19,10 @@ RULE = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette for route types -OKABE_ITO = { +IMPRINT = { "express": "#009E73", # Position 1 - brand green - "regional": "#D55E00", # Position 2 - vermillion - "local": "#0072B2", # Position 3 - blue + "regional": "#C475FD", # Position 2 - vermillion + "local": "#4467A3", # Position 3 - blue } np.random.seed(42) @@ -117,7 +117,7 @@ def get_edge_offset(source, target, route_idx): x1_draw = x1_off - shrink * dx / length y1_draw = y1_off - shrink * dy / length - color = OKABE_ITO[route["type"]] + color = IMPRINT[route["type"]] show_in_legend = route["type"] not in legend_items legend_items.add(route["type"]) diff --git a/plots/ohlc-bar/implementations/python/plotly.py b/plots/ohlc-bar/implementations/python/plotly.py index 5e68417e20..105531988c 100644 --- a/plots/ohlc-bar/implementations/python/plotly.py +++ b/plots/ohlc-bar/implementations/python/plotly.py @@ -27,7 +27,7 @@ # Okabe-Ito palette for up/down coloring BRAND = "#009E73" # Position 1 - bluish green, first series UP_COLOR = BRAND # Use brand green for up days -DOWN_COLOR = "#D55E00" # Position 2 - vermillion for down days +DOWN_COLOR = "#AE3030" # imprint red — down days # Data - Generate realistic stock price data for 45 trading days np.random.seed(42) diff --git a/plots/parallel-basic/implementations/python/plotly.py b/plots/parallel-basic/implementations/python/plotly.py index 080991172e..60a5d802c6 100644 --- a/plots/parallel-basic/implementations/python/plotly.py +++ b/plots/parallel-basic/implementations/python/plotly.py @@ -18,14 +18,14 @@ INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -# Okabe-Ito discrete colorscale: Setosa=#009E73, Versicolor=#D55E00, Virginica=#0072B2 +# Okabe-Ito discrete colorscale: Setosa=#009E73, Versicolor=#C475FD, Virginica=#4467A3 OI_COLORSCALE = [ [0.0, "#009E73"], [0.33, "#009E73"], - [0.33, "#D55E00"], - [0.67, "#D55E00"], - [0.67, "#0072B2"], - [1.0, "#0072B2"], + [0.33, "#C475FD"], + [0.67, "#C475FD"], + [0.67, "#4467A3"], + [1.0, "#4467A3"], ] # Data - Iris-like dataset for multivariate demonstration diff --git a/plots/parallel-categories-basic/implementations/python/plotly.py b/plots/parallel-categories-basic/implementations/python/plotly.py index 90d911e0a8..421b8dd992 100644 --- a/plots/parallel-categories-basic/implementations/python/plotly.py +++ b/plots/parallel-categories-basic/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito colors for categorical data -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Titanic survival data with multiple categorical dimensions df = sns.load_dataset("titanic") @@ -63,7 +63,7 @@ fig = go.Figure( go.Parcats( dimensions=dimensions, - line={"color": color_values, "colorscale": [[0, OKABE_ITO[1]], [1, OKABE_ITO[0]]], "shape": "hspline"}, + line={"color": color_values, "colorscale": [[0, IMPRINT[1]], [1, IMPRINT[0]]], "shape": "hspline"}, hoveron="color", hoverinfo="count+probability", arrangement="freeform", diff --git a/plots/parliament-basic/implementations/python/plotly.py b/plots/parliament-basic/implementations/python/plotly.py index 9f1db4f70f..5da1b3d3c8 100644 --- a/plots/parliament-basic/implementations/python/plotly.py +++ b/plots/parliament-basic/implementations/python/plotly.py @@ -29,7 +29,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (positions 1→6, first is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data - Fictional parliament with neutral party names parties = [ @@ -43,7 +43,7 @@ # Assign Okabe-Ito colors to parties for i, party in enumerate(parties): - party["color"] = OKABE_ITO[i % len(OKABE_ITO)] + party["color"] = IMPRINT[i % len(IMPRINT)] total_seats = sum(p["seats"] for p in parties) majority_threshold = total_seats // 2 + 1 diff --git a/plots/phase-diagram/implementations/python/plotly.py b/plots/phase-diagram/implementations/python/plotly.py index 3767c3c3c3..c2761ed615 100644 --- a/plots/phase-diagram/implementations/python/plotly.py +++ b/plots/phase-diagram/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.20)" if THEME == "light" else "rgba(240,239,232,0.20)" BRAND = "#009E73" # Okabe-Ito position 1 -ACCENT_1 = "#D55E00" # Okabe-Ito position 2 +ACCENT_1 = "#C475FD" # Okabe-Ito position 2 # Data - Damped pendulum showing spiral convergence to equilibrium np.random.seed(42) diff --git a/plots/pie-drilldown/implementations/python/plotly.py b/plots/pie-drilldown/implementations/python/plotly.py index f4ce1ad69a..09f979af8d 100644 --- a/plots/pie-drilldown/implementations/python/plotly.py +++ b/plots/pie-drilldown/implementations/python/plotly.py @@ -20,7 +20,7 @@ ACCENT = "#009E73" # Okabe-Ito palette (first series must be #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Hierarchical data for sales regions hierarchy = { @@ -58,30 +58,30 @@ # Color mapping using Okabe-Ito (first series is always #009E73 for brand) colors = { - "North America": OKABE_ITO[0], # #009E73 - brand green - "Europe": OKABE_ITO[1], # #D55E00 - vermillion - "Asia Pacific": OKABE_ITO[2], # #0072B2 - blue - "Latin America": OKABE_ITO[3], # #CC79A7 - reddish purple + "North America": IMPRINT[0], # #009E73 - brand green + "Europe": IMPRINT[1], # #C475FD - vermillion + "Asia Pacific": IMPRINT[2], # #4467A3 - blue + "Latin America": IMPRINT[3], # #BD8233 - reddish purple } # Lighter shades for subcategories (derived from main colors with opacity in hover) sub_colors = { # North America shades - "USA": OKABE_ITO[0], - "Canada": OKABE_ITO[0], - "Mexico": OKABE_ITO[0], + "USA": IMPRINT[0], + "Canada": IMPRINT[0], + "Mexico": IMPRINT[0], # Europe shades - "UK": OKABE_ITO[1], - "Germany": OKABE_ITO[1], - "France": OKABE_ITO[1], + "UK": IMPRINT[1], + "Germany": IMPRINT[1], + "France": IMPRINT[1], # Asia Pacific shades - "Japan": OKABE_ITO[2], - "Australia": OKABE_ITO[2], - "India": OKABE_ITO[2], + "Japan": IMPRINT[2], + "Australia": IMPRINT[2], + "India": IMPRINT[2], # Latin America shades - "Brazil": OKABE_ITO[3], - "Argentina": OKABE_ITO[3], - "Chile": OKABE_ITO[3], + "Brazil": IMPRINT[3], + "Argentina": IMPRINT[3], + "Chile": IMPRINT[3], } # Get data for top level diff --git a/plots/point-and-figure-basic/implementations/python/plotly.py b/plots/point-and-figure-basic/implementations/python/plotly.py index 1ea8596387..cb8cd0f393 100644 --- a/plots/point-and-figure-basic/implementations/python/plotly.py +++ b/plots/point-and-figure-basic/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" COLOR_X = "#009E73" # Okabe-Ito pos 1 — X (Rising), colorblind-safe -COLOR_O = "#D55E00" # Okabe-Ito pos 2 — O (Falling), colorblind-safe +COLOR_O = "#AE3030" # imprint red — O (Falling) # Data — synthetic stock price with distinct trend phases np.random.seed(42) diff --git a/plots/polar-bar/implementations/python/plotly.py b/plots/polar-bar/implementations/python/plotly.py index 4ebf57c6a9..fc52bb5970 100644 --- a/plots/polar-bar/implementations/python/plotly.py +++ b/plots/polar-bar/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] wind_speed_labels = ["Light (0-10 km/h)", "Moderate (10-20 km/h)", "Strong (20+ km/h)"] # Data: Wind speed distribution by direction (8 compass points) @@ -35,7 +35,7 @@ fig = go.Figure() # Add stacked bars for each wind speed category -for data, label, color in zip([light, moderate, strong], wind_speed_labels, OKABE_ITO, strict=True): +for data, label, color in zip([light, moderate, strong], wind_speed_labels, IMPRINT, strict=True): fig.add_trace( go.Barpolar( r=data, diff --git a/plots/polar-line/implementations/python/plotly.py b/plots/polar-line/implementations/python/plotly.py index e42877febb..2c62f1a30a 100644 --- a/plots/polar-line/implementations/python/plotly.py +++ b/plots/polar-line/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data - Average hourly temperature pattern (two seasons) np.random.seed(42) @@ -49,8 +49,8 @@ theta=hours_closed, mode="lines+markers", name="Summer", - line=dict(color=OKABE_ITO[0], width=4), - marker=dict(size=10, color=OKABE_ITO[0]), + line=dict(color=IMPRINT[0], width=4), + marker=dict(size=10, color=IMPRINT[0]), hovertemplate="Hour: %{theta}°
Temp: %{r:.1f}°CSummer", ) ) @@ -62,8 +62,8 @@ theta=hours_closed, mode="lines+markers", name="Winter", - line=dict(color=OKABE_ITO[1], width=4), - marker=dict(size=10, color=OKABE_ITO[1]), + line=dict(color=IMPRINT[1], width=4), + marker=dict(size=10, color=IMPRINT[1]), hovertemplate="Hour: %{theta}°
Temp: %{r:.1f}°CWinter", ) ) diff --git a/plots/polar-scatter/implementations/python/plotly.py b/plots/polar-scatter/implementations/python/plotly.py index 78688837c2..509e386480 100644 --- a/plots/polar-scatter/implementations/python/plotly.py +++ b/plots/polar-scatter/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - synthetic wind measurements with prevailing directions np.random.seed(42) @@ -54,7 +54,7 @@ fig = go.Figure() # Color mapping for time of day using Okabe-Ito -colors = {"Morning": OKABE_ITO[0], "Afternoon": OKABE_ITO[1], "Evening": OKABE_ITO[2]} +colors = {"Morning": IMPRINT[0], "Afternoon": IMPRINT[1], "Evening": IMPRINT[2]} # Add traces for each time period for period in ["Morning", "Afternoon", "Evening"]: diff --git a/plots/precision-recall/implementations/python/plotly.py b/plots/precision-recall/implementations/python/plotly.py index a23c113e82..1fdaad26e6 100644 --- a/plots/precision-recall/implementations/python/plotly.py +++ b/plots/precision-recall/implementations/python/plotly.py @@ -21,7 +21,7 @@ # Okabe-Ito palette BRAND = "#009E73" # Position 1, first series -SECONDARY = "#E69F00" # Position 5, orange +SECONDARY = "#BD8233" # imprint ochre — secondary reference (red is reserved for semantic bad) # Data - Simulate a binary classification scenario (fraud detection) np.random.seed(42) diff --git a/plots/pyramid-basic/implementations/python/plotly.py b/plots/pyramid-basic/implementations/python/plotly.py index 96695418b2..576bd616c0 100644 --- a/plots/pyramid-basic/implementations/python/plotly.py +++ b/plots/pyramid-basic/implementations/python/plotly.py @@ -43,7 +43,7 @@ x=female_population, orientation="h", name="Female", - marker_color="#D55E00", # Okabe-Ito position 2 + marker_color="#C475FD", # Okabe-Ito position 2 hovertemplate="Female
Age: %{y}
Population: %{customdata:,}k", customdata=female_population, ) diff --git a/plots/qq-basic/implementations/python/plotly.py b/plots/qq-basic/implementations/python/plotly.py index d7f4450eb9..c25f18cfe3 100644 --- a/plots/qq-basic/implementations/python/plotly.py +++ b/plots/qq-basic/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 — Q-Q scatter points -REF_COLOR = "#D55E00" # Okabe-Ito position 2 — reference line +REF_COLOR = "#C475FD" # Okabe-Ito position 2 — reference line # Data - sample with slight positive skew to demonstrate Q-Q plot interpretation np.random.seed(42) diff --git a/plots/radar-basic/implementations/python/plotly.py b/plots/radar-basic/implementations/python/plotly.py index 07cb05781e..4e55eb1a2c 100644 --- a/plots/radar-basic/implementations/python/plotly.py +++ b/plots/radar-basic/implementations/python/plotly.py @@ -15,9 +15,9 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data - Employee performance comparison across competencies categories = ["Communication", "Technical Skills", "Teamwork", "Problem Solving", "Leadership", "Creativity"] @@ -38,8 +38,8 @@ theta=categories_closed, fill="toself", fillcolor="rgba(0, 158, 115, 0.25)", - line={"color": OKABE_ITO[0], "width": 3}, - marker={"size": 12, "color": OKABE_ITO[0]}, + line={"color": IMPRINT[0], "width": 3}, + marker={"size": 12, "color": IMPRINT[0]}, name="Senior Developer", hovertemplate="Senior Developer
%{theta}: %{r}", ) @@ -50,9 +50,9 @@ r=junior_closed, theta=categories_closed, fill="toself", - fillcolor="rgba(213, 94, 0, 0.25)", - line={"color": OKABE_ITO[1], "width": 3}, - marker={"size": 12, "color": OKABE_ITO[1]}, + fillcolor="rgba(196, 117, 253, 0.25)", + line={"color": IMPRINT[1], "width": 3}, + marker={"size": 12, "color": IMPRINT[1]}, name="Junior Developer", hovertemplate="Junior Developer
%{theta}: %{r}", ) diff --git a/plots/radar-multi/implementations/python/plotly.py b/plots/radar-multi/implementations/python/plotly.py index 3bc8037aa5..5267ca0984 100644 --- a/plots/radar-multi/implementations/python/plotly.py +++ b/plots/radar-multi/implementations/python/plotly.py @@ -15,10 +15,10 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" # Okabe-Ito palette (first series always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] # Data - Product comparison across multiple attributes categories = ["Performance", "Reliability", "Price Value", "Support", "Ease of Use", "Features"] @@ -44,7 +44,7 @@ theta=categories_closed, fill="toself", fillcolor="rgba(0, 158, 115, 0.25)", - line={"color": OKABE_ITO[0], "width": 3}, + line={"color": IMPRINT[0], "width": 3}, name="Product A (Premium)", marker={"size": 10}, ) @@ -56,8 +56,8 @@ r=product_b_closed, theta=categories_closed, fill="toself", - fillcolor="rgba(213, 94, 0, 0.25)", - line={"color": OKABE_ITO[1], "width": 3}, + fillcolor="rgba(196, 117, 253, 0.25)", + line={"color": IMPRINT[1], "width": 3}, name="Product B (Budget)", marker={"size": 10}, ) @@ -69,8 +69,8 @@ r=product_c_closed, theta=categories_closed, fill="toself", - fillcolor="rgba(0, 114, 178, 0.25)", - line={"color": OKABE_ITO[2], "width": 3}, + fillcolor="rgba(68, 103, 163, 0.25)", + line={"color": IMPRINT[2], "width": 3}, name="Product C (Pro)", marker={"size": 10}, ) diff --git a/plots/range-interval/implementations/python/plotly.py b/plots/range-interval/implementations/python/plotly.py index 2d71b3a3bd..c4754d66dd 100644 --- a/plots/range-interval/implementations/python/plotly.py +++ b/plots/range-interval/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito palette BRAND = "#009E73" # Primary series -SECONDARY = "#D55E00" # Secondary series +SECONDARY = "#C475FD" # Secondary series # Data: Monthly temperature ranges (°C) for a temperate climate city np.random.seed(42) diff --git a/plots/renko-basic/implementations/python/plotly.py b/plots/renko-basic/implementations/python/plotly.py index 2d23ea4d69..7ac7176122 100644 --- a/plots/renko-basic/implementations/python/plotly.py +++ b/plots/renko-basic/implementations/python/plotly.py @@ -29,7 +29,7 @@ # Okabe-Ito palette BULLISH = "#009E73" # Bluish green - position 1 (brand) -BEARISH = "#D55E00" # Vermillion - position 2 +BEARISH = "#AE3030" # imprint red — down bricks # Data - Generate synthetic stock price data np.random.seed(42) diff --git a/plots/residual-plot/implementations/python/plotly.py b/plots/residual-plot/implementations/python/plotly.py index da9c8f2e44..066e1a7c33 100644 --- a/plots/residual-plot/implementations/python/plotly.py +++ b/plots/residual-plot/implementations/python/plotly.py @@ -27,7 +27,7 @@ # Okabe-Ito palette BRAND = "#009E73" -ACCENT = "#D55E00" +ACCENT = "#C475FD" NEUTRAL = "#1A1A1A" if THEME == "light" else "#E8E8E0" # Data - Generate realistic regression scenario with varying residual patterns diff --git a/plots/roc-curve/implementations/python/plotly.py b/plots/roc-curve/implementations/python/plotly.py index 67ad32b10c..620a8ec861 100644 --- a/plots/roc-curve/implementations/python/plotly.py +++ b/plots/roc-curve/implementations/python/plotly.py @@ -24,7 +24,7 @@ # Okabe-Ito palette BRAND_1 = "#009E73" -BRAND_2 = "#D55E00" +BRAND_2 = "#C475FD" NEUTRAL = "#888888" # Generate classification data diff --git a/plots/sankey-basic/implementations/python/plotly.py b/plots/sankey-basic/implementations/python/plotly.py index 5cc3ac3fa6..498feff5ee 100644 --- a/plots/sankey-basic/implementations/python/plotly.py +++ b/plots/sankey-basic/implementations/python/plotly.py @@ -16,8 +16,8 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito palette for source nodes (positions 1-4) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] -SOURCE_RGBA = ["rgba(0,158,115,0.4)", "rgba(213,94,0,0.4)", "rgba(0,114,178,0.4)", "rgba(204,121,167,0.4)"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] +SOURCE_RGBA = ["rgba(0, 158, 115, 0.4)", "rgba(196, 117, 253, 0.4)", "rgba(68, 103, 163, 0.4)", "rgba(189, 130, 51, 0.4)"] # Data - Energy flow from sources to sectors (TWh) sources = ["Coal", "Natural Gas", "Nuclear", "Renewables"] @@ -46,7 +46,7 @@ values = [f[2] for f in flows] # Source nodes use Okabe-Ito colors; target nodes use INK_SOFT -node_colors = OKABE_ITO + [INK_SOFT] * 4 +node_colors = IMPRINT + [INK_SOFT] * 4 link_colors = [SOURCE_RGBA[s] for s in source_indices] # Plot diff --git a/plots/scatter-animated-controls/implementations/python/plotly.py b/plots/scatter-animated-controls/implementations/python/plotly.py index 65b1a6a6d6..cf585109fb 100644 --- a/plots/scatter-animated-controls/implementations/python/plotly.py +++ b/plots/scatter-animated-controls/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] np.random.seed(42) @@ -69,7 +69,7 @@ size_max=80, range_x=[0, df["GDP per Capita ($)"].max() * 1.1], range_y=[50, 88], - color_discrete_sequence=OKABE_ITO, + color_discrete_sequence=IMPRINT, ) fig.update_layout( diff --git a/plots/scatter-annotated/implementations/python/plotly.py b/plots/scatter-annotated/implementations/python/plotly.py index 6c519191fc..d756f82847 100644 --- a/plots/scatter-annotated/implementations/python/plotly.py +++ b/plots/scatter-annotated/implementations/python/plotly.py @@ -18,7 +18,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -BRAND_ACCENT = "#D55E00" +BRAND_ACCENT = "#C475FD" # Data - Top tech companies by market cap and revenue np.random.seed(42) diff --git a/plots/scatter-categorical/implementations/python/plotly.py b/plots/scatter-categorical/implementations/python/plotly.py index aa83d1fb61..46d6944044 100644 --- a/plots/scatter-categorical/implementations/python/plotly.py +++ b/plots/scatter-categorical/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is ALWAYS #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Product performance across regions np.random.seed(42) @@ -44,7 +44,7 @@ y=data[region]["y"], mode="markers", name=region, - marker={"size": 14, "color": OKABE_ITO[i], "opacity": 0.7, "line": {"width": 1, "color": PAGE_BG}}, + marker={"size": 14, "color": IMPRINT[i], "opacity": 0.7, "line": {"width": 1, "color": PAGE_BG}}, hovertemplate=f"{region}
Marketing: %{{x:.1f}}%
Sales: %{{y:.1f}}%", ) ) diff --git a/plots/scatter-embedding/implementations/python/plotly.py b/plots/scatter-embedding/implementations/python/plotly.py index be239cb8b3..87ec7a70c8 100644 --- a/plots/scatter-embedding/implementations/python/plotly.py +++ b/plots/scatter-embedding/implementations/python/plotly.py @@ -20,7 +20,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data — simulate document embeddings in 50-dimensional topic space np.random.seed(42) @@ -45,7 +45,7 @@ y=X_2d[mask, 1], mode="markers", name=topic, - marker={"color": OKABE_ITO[i], "size": 8, "opacity": 0.65, "line": {"color": PAGE_BG, "width": 0.5}}, + marker={"color": IMPRINT[i], "size": 8, "opacity": 0.65, "line": {"color": PAGE_BG, "width": 0.5}}, ) ) diff --git a/plots/scatter-matrix-interactive/implementations/python/plotly.py b/plots/scatter-matrix-interactive/implementations/python/plotly.py index e55748408a..5841fc0da5 100644 --- a/plots/scatter-matrix-interactive/implementations/python/plotly.py +++ b/plots/scatter-matrix-interactive/implementations/python/plotly.py @@ -22,7 +22,7 @@ GRID_LIGHT = "rgba(26,26,23,0.05)" if THEME == "light" else "rgba(240,239,232,0.05)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Using Iris dataset for multivariate exploration iris = sns.load_dataset("iris") @@ -36,7 +36,7 @@ # Species info species_list = ["Setosa", "Versicolor", "Virginica"] -color_map = {s: OKABE_ITO[i] for i, s in enumerate(species_list)} +color_map = {s: IMPRINT[i] for i, s in enumerate(species_list)} # Create 4x4 subplot grid n = len(cols) diff --git a/plots/scatter-matrix/implementations/python/plotly.py b/plots/scatter-matrix/implementations/python/plotly.py index 045563a052..7351a5f39a 100644 --- a/plots/scatter-matrix/implementations/python/plotly.py +++ b/plots/scatter-matrix/implementations/python/plotly.py @@ -21,10 +21,10 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand, first series) - "#D55E00", # vermillion - "#0072B2", # blue + "#C475FD", # vermillion + "#4467A3", # blue ] # Data - Weather station measurements across 4 variables @@ -83,7 +83,7 @@ # Variables for matrix dimensions = ["Temperature (°C)", "Humidity (%)", "Pressure (hPa)", "Wind Speed (m/s)"] region_list = ["Coastal", "Mountain", "Desert"] -region_colors = {"Coastal": OKABE_ITO[0], "Mountain": OKABE_ITO[1], "Desert": OKABE_ITO[2]} +region_colors = {"Coastal": IMPRINT[0], "Mountain": IMPRINT[1], "Desert": IMPRINT[2]} n_dims = len(dimensions) # Create subplots grid diff --git a/plots/scatter-regression-linear/implementations/python/plotly.py b/plots/scatter-regression-linear/implementations/python/plotly.py index a80a697735..5736d84f10 100644 --- a/plots/scatter-regression-linear/implementations/python/plotly.py +++ b/plots/scatter-regression-linear/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" -ACCENT = "#D55E00" +ACCENT = "#C475FD" # Data - study hours vs exam scores np.random.seed(42) diff --git a/plots/scatter-regression-lowess/implementations/python/plotly.py b/plots/scatter-regression-lowess/implementations/python/plotly.py index 5f5921c2e2..481bf8bc4f 100644 --- a/plots/scatter-regression-lowess/implementations/python/plotly.py +++ b/plots/scatter-regression-lowess/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" BRAND = "#009E73" # Okabe-Ito position 1 -ACCENT = "#D55E00" # Okabe-Ito position 2 +ACCENT = "#C475FD" # Okabe-Ito position 2 # Data - Enzyme kinetics: realistic biological dose-response relationship # Different structure than seaborn: exponential saturation curve with noise diff --git a/plots/scatter-regression-polynomial/implementations/python/plotly.py b/plots/scatter-regression-polynomial/implementations/python/plotly.py index b8bb347588..cf81248313 100644 --- a/plots/scatter-regression-polynomial/implementations/python/plotly.py +++ b/plots/scatter-regression-polynomial/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito palette - first series is always #009E73 BRAND = "#009E73" -ACCENT = "#D55E00" +ACCENT = "#C475FD" # Data - Temperature vs Energy Consumption (environmental/building efficiency) np.random.seed(42) diff --git a/plots/scatter-text/implementations/python/plotly.py b/plots/scatter-text/implementations/python/plotly.py index 548d038bd9..1f7b5de1d9 100644 --- a/plots/scatter-text/implementations/python/plotly.py +++ b/plots/scatter-text/implementations/python/plotly.py @@ -18,14 +18,14 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette for categories -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple - "#E69F00", # orange - "#56B4E9", # sky blue - "#F0E442", # yellow + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple + "#AE3030", # orange + "#2ABCCD", # sky blue + "#954477", # yellow "#1A1A1A" if THEME == "light" else "#E8E8E0", # adaptive neutral ] @@ -179,7 +179,7 @@ y_cat = [y[i] for i in range(len(y)) if mask[i]] labels_cat = [labels[i] for i in range(len(labels)) if mask[i]] - color = OKABE_ITO[cat_idx] + color = IMPRINT[cat_idx] category_colors[cat_name] = color # Create hover text with detailed information diff --git a/plots/shap-waterfall/implementations/python/plotly.py b/plots/shap-waterfall/implementations/python/plotly.py index 1944bb287a..ad3c9d1ea1 100644 --- a/plots/shap-waterfall/implementations/python/plotly.py +++ b/plots/shap-waterfall/implementations/python/plotly.py @@ -19,8 +19,8 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # SHAP semantic colors (Okabe-Ito positions used for semantic encoding) -POS_COLOR = "#D55E00" # vermillion — positive SHAP (pushes prediction up) -NEG_COLOR = "#0072B2" # blue — negative SHAP (pushes prediction down) +POS_COLOR = "#AE3030" # imprint red — positive SHAP (pushes prediction up) +NEG_COLOR = "#4467A3" # blue — negative SHAP (pushes prediction down) REF_COLOR = "#009E73" # brand green — reference bars (base & final) # Data — credit risk model SHAP waterfall for a single high-risk loan applicant diff --git a/plots/skewt-logp-atmospheric/implementations/python/plotly.py b/plots/skewt-logp-atmospheric/implementations/python/plotly.py index 763c905722..3abe004a9c 100644 --- a/plots/skewt-logp-atmospheric/implementations/python/plotly.py +++ b/plots/skewt-logp-atmospheric/implementations/python/plotly.py @@ -16,16 +16,16 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" BRAND = "#009E73" # Okabe-Ito pos 1 — temperature profile -C_DEWPT = "#D55E00" # Okabe-Ito pos 2 — dewpoint profile +C_DEWPT = "#C475FD" # Okabe-Ito pos 2 — dewpoint profile # Reference line colors: subtle, theme-adaptive -C_ISO = "rgba(80,80,80,0.22)" if THEME == "light" else "rgba(180,180,180,0.28)" -C_DRY = "rgba(213,94,0,0.22)" if THEME == "light" else "rgba(213,94,0,0.38)" -C_MOIST = "rgba(0,114,178,0.22)" if THEME == "light" else "rgba(0,114,178,0.38)" -C_MIX = "rgba(0,158,115,0.22)" if THEME == "light" else "rgba(0,158,115,0.38)" +C_ISO = "rgba(80, 80, 80, 0.22)" if THEME == "light" else "rgba(180, 180, 180, 0.28)" +C_DRY = "rgba(196, 117, 253, 0.22)" if THEME == "light" else "rgba(196, 117, 253, 0.38)" +C_MOIST = "rgba(68, 103, 163, 0.22)" if THEME == "light" else "rgba(68, 103, 163, 0.38)" +C_MIX = "rgba(0, 158, 115, 0.22)" if THEME == "light" else "rgba(0, 158, 115, 0.38)" # Skew-T transform: °C shift per log10 decade of pressure from 1000 hPa SKEW = 30.0 diff --git a/plots/slope-basic/implementations/python/plotly.py b/plots/slope-basic/implementations/python/plotly.py index e21065090f..706b62e74e 100644 --- a/plots/slope-basic/implementations/python/plotly.py +++ b/plots/slope-basic/implementations/python/plotly.py @@ -20,7 +20,7 @@ # Okabe-Ito: increase = brand green, decrease = vermillion, flat = adaptive neutral COLOR_UP = "#009E73" -COLOR_DOWN = "#D55E00" +COLOR_DOWN = "#AE3030" # imprint red — decrease COLOR_FLAT = INK_MUTED # Data - Product sales Q1 vs Q4 comparison (10 products showing various patterns) diff --git a/plots/smith-chart-basic/implementations/python/plotly.py b/plots/smith-chart-basic/implementations/python/plotly.py index cca8859897..642318f82e 100644 --- a/plots/smith-chart-basic/implementations/python/plotly.py +++ b/plots/smith-chart-basic/implementations/python/plotly.py @@ -17,7 +17,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" BRAND = "#009E73" # Okabe-Ito position 1 — impedance locus -ACCENT = "#D55E00" # Okabe-Ito position 2 — matched condition marker +ACCENT = "#C475FD" # Okabe-Ito position 2 — matched condition marker # Smith chart grid color (slightly stronger than RULE for chart structure) SMITH_GRID = "rgba(74,74,68,0.30)" if THEME == "light" else "rgba(184,183,176,0.30)" diff --git a/plots/sn-curve-basic/implementations/python/plotly.py b/plots/sn-curve-basic/implementations/python/plotly.py index 281ef75f4c..e88d44647a 100644 --- a/plots/sn-curve-basic/implementations/python/plotly.py +++ b/plots/sn-curve-basic/implementations/python/plotly.py @@ -20,10 +20,10 @@ # Okabe-Ito palette BRAND = "#009E73" # position 1 — Basquin fit line -C2 = "#D55E00" # position 2 — test data markers -C3 = "#0072B2" # position 3 — ultimate strength -C4 = "#CC79A7" # position 4 — yield strength -C5 = "#E69F00" # position 5 — endurance limit +C2 = "#C475FD" # position 2 — test data markers +C3 = "#4467A3" # position 3 — ultimate strength +C4 = "#BD8233" # position 4 — yield strength +C5 = "#AE3030" # position 5 — endurance limit # Data: Steel fatigue test data (Basquin model) np.random.seed(42) diff --git a/plots/streamgraph-basic/implementations/python/plotly.py b/plots/streamgraph-basic/implementations/python/plotly.py index 41d0f521dc..ce1ce69ce8 100644 --- a/plots/streamgraph-basic/implementations/python/plotly.py +++ b/plots/streamgraph-basic/implementations/python/plotly.py @@ -25,7 +25,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette — first series always #009E73 -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD"] # Data - Monthly streaming hours by music genre over 2 years np.random.seed(42) @@ -71,9 +71,9 @@ x=x_fill, y=y_fill, fill="toself", - fillcolor=OKABE_ITO[i], + fillcolor=IMPRINT[i], opacity=opacity, - line={"color": OKABE_ITO[i], "width": 0.5, "shape": "spline", "smoothing": 1.0}, + line={"color": IMPRINT[i], "width": 0.5, "shape": "spline", "smoothing": 1.0}, name=genre, mode="none", hoverinfo="name+x", diff --git a/plots/strip-basic/implementations/python/plotly.py b/plots/strip-basic/implementations/python/plotly.py index 16d2639e85..7065e0af1c 100644 --- a/plots/strip-basic/implementations/python/plotly.py +++ b/plots/strip-basic/implementations/python/plotly.py @@ -19,7 +19,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette — first series always #009E73 -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data - Survey response scores grouped by demographic category np.random.seed(42) @@ -47,7 +47,7 @@ y=values, mode="markers", name=cat, - marker={"size": 14, "opacity": 0.6, "color": OKABE_ITO[i]}, + marker={"size": 14, "opacity": 0.6, "color": IMPRINT[i]}, hovertemplate=f"{cat}
Value: %{{y:.1f}}", ) ) diff --git a/plots/subplot-grid/implementations/python/plotly.py b/plots/subplot-grid/implementations/python/plotly.py index 21608dc4cb..899fe1804a 100644 --- a/plots/subplot-grid/implementations/python/plotly.py +++ b/plots/subplot-grid/implementations/python/plotly.py @@ -26,7 +26,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data - Financial dashboard example np.random.seed(42) @@ -62,18 +62,18 @@ # Subplot 1: Line chart - Stock price with moving average fig.add_trace( - go.Scatter(x=dates, y=price, mode="lines", name="Price", line={"color": OKABE_ITO[0], "width": 3}), row=1, col=1 + go.Scatter(x=dates, y=price, mode="lines", name="Price", line={"color": IMPRINT[0], "width": 3}), row=1, col=1 ) fig.add_trace( go.Scatter( - x=dates, y=ma_20, mode="lines", name="20-day MA", line={"color": OKABE_ITO[1], "width": 2, "dash": "dash"} + x=dates, y=ma_20, mode="lines", name="20-day MA", line={"color": IMPRINT[1], "width": 2, "dash": "dash"} ), row=1, col=1, ) # Subplot 2: Bar chart - Volume -volume_colors = [OKABE_ITO[0] if r >= 0 else OKABE_ITO[1] for r in returns] +volume_colors = [IMPRINT[0] if r >= 0 else IMPRINT[1] for r in returns] fig.add_trace(go.Bar(x=dates, y=volume, name="Volume", marker={"color": volume_colors, "opacity": 0.8}), row=1, col=2) # Subplot 3: Histogram - Daily returns distribution @@ -82,7 +82,7 @@ x=daily_returns, nbinsx=20, name="Returns", - marker={"color": OKABE_ITO[0], "opacity": 0.75, "line": {"color": PAGE_BG, "width": 1}}, + marker={"color": IMPRINT[0], "opacity": 0.75, "line": {"color": PAGE_BG, "width": 1}}, ), row=2, col=1, @@ -95,7 +95,7 @@ y=price, mode="markers", name="Price-Volume", - marker={"color": OKABE_ITO[0], "size": 14, "opacity": 0.7, "line": {"color": PAGE_BG, "width": 1}}, + marker={"color": IMPRINT[0], "size": 14, "opacity": 0.7, "line": {"color": PAGE_BG, "width": 1}}, ), row=2, col=2, diff --git a/plots/subplot-mosaic/implementations/python/plotly.py b/plots/subplot-mosaic/implementations/python/plotly.py index 49811a90e4..fc5b142c13 100644 --- a/plots/subplot-mosaic/implementations/python/plotly.py +++ b/plots/subplot-mosaic/implementations/python/plotly.py @@ -21,14 +21,14 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = [ +IMPRINT = [ "#009E73", # brand — first series - "#D55E00", - "#0072B2", - "#CC79A7", - "#E69F00", - "#56B4E9", - "#F0E442", + "#C475FD", + "#4467A3", + "#BD8233", + "#AE3030", + "#2ABCCD", + "#954477", ] # Data @@ -86,9 +86,9 @@ x=dates, y=revenue, mode="lines", - line={"color": OKABE_ITO[0], "width": 4}, + line={"color": IMPRINT[0], "width": 4}, fill="tozeroy", - fillcolor=f"rgba({int(OKABE_ITO[0][1:3], 16)}, {int(OKABE_ITO[0][3:5], 16)}, {int(OKABE_ITO[0][5:7], 16)}, 0.2)", + fillcolor=f"rgba({int(IMPRINT[0][1:3], 16)}, {int(IMPRINT[0][3:5], 16)}, {int(IMPRINT[0][5:7], 16)}, 0.2)", name="Revenue", ), row=1, @@ -96,7 +96,7 @@ ) # B: Monthly sales bar (top right) -fig.add_trace(go.Bar(x=months, y=monthly_sales, marker_color=OKABE_ITO[1], name="Monthly"), row=1, col=3) +fig.add_trace(go.Bar(x=months, y=monthly_sales, marker_color=IMPRINT[1], name="Monthly"), row=1, col=3) # C: Product scatter (middle spanning) — INCREASED marker size fig.add_trace( @@ -104,7 +104,7 @@ x=product_x, y=product_y, mode="markers", - marker={"size": 16, "color": OKABE_ITO[0], "opacity": 0.8}, + marker={"size": 16, "color": IMPRINT[0], "opacity": 0.8}, name="Products", ), row=2, @@ -117,7 +117,7 @@ y=categories, x=cat_values, orientation="h", - marker_color=[OKABE_ITO[0], OKABE_ITO[1], OKABE_ITO[2], OKABE_ITO[3], OKABE_ITO[4]], + marker_color=[IMPRINT[0], IMPRINT[1], IMPRINT[2], IMPRINT[3], IMPRINT[4]], name="Categories", ), row=2, @@ -130,9 +130,9 @@ x=list(range(30)), y=metric_1_history, mode="lines", - line={"color": OKABE_ITO[0], "width": 3}, + line={"color": IMPRINT[0], "width": 3}, fill="tozeroy", - fillcolor=f"rgba({int(OKABE_ITO[0][1:3], 16)}, {int(OKABE_ITO[0][3:5], 16)}, {int(OKABE_ITO[0][5:7], 16)}, 0.25)", + fillcolor=f"rgba({int(IMPRINT[0][1:3], 16)}, {int(IMPRINT[0][3:5], 16)}, {int(IMPRINT[0][5:7], 16)}, 0.25)", name="Efficiency", ), row=3, @@ -145,9 +145,9 @@ x=list(range(30)), y=metric_2_history, mode="lines", - line={"color": OKABE_ITO[1], "width": 3}, + line={"color": IMPRINT[1], "width": 3}, fill="tozeroy", - fillcolor=f"rgba({int(OKABE_ITO[1][1:3], 16)}, {int(OKABE_ITO[1][3:5], 16)}, {int(OKABE_ITO[1][5:7], 16)}, 0.25)", + fillcolor=f"rgba({int(IMPRINT[1][1:3], 16)}, {int(IMPRINT[1][3:5], 16)}, {int(IMPRINT[1][5:7], 16)}, 0.25)", name="Quality", ), row=3, @@ -160,9 +160,9 @@ x=list(range(30)), y=metric_3_history, mode="lines", - line={"color": OKABE_ITO[2], "width": 3}, + line={"color": IMPRINT[2], "width": 3}, fill="tozeroy", - fillcolor=f"rgba({int(OKABE_ITO[2][1:3], 16)}, {int(OKABE_ITO[2][3:5], 16)}, {int(OKABE_ITO[2][5:7], 16)}, 0.25)", + fillcolor=f"rgba({int(IMPRINT[2][1:3], 16)}, {int(IMPRINT[2][3:5], 16)}, {int(IMPRINT[2][5:7], 16)}, 0.25)", name="Response", ), row=3, diff --git a/plots/sunburst-basic/implementations/python/plotly.py b/plots/sunburst-basic/implementations/python/plotly.py index 33c5a80307..55ff1e9880 100644 --- a/plots/sunburst-basic/implementations/python/plotly.py +++ b/plots/sunburst-basic/implementations/python/plotly.py @@ -72,18 +72,18 @@ colors = [ ELEVATED_BG, # Company root — adapts cleanly to both light and dark themes "#009E73", # Engineering — Okabe-Ito #1 (dominant: 37.5%) - "#D55E00", # Sales — Okabe-Ito #2 - "#0072B2", # Marketing — Okabe-Ito #3 - "#CC79A7", # Operations — Okabe-Ito #4 - "#00B589", # Backend — lighter green + "#C475FD", # Sales — Okabe-Ito #2 + "#4467A3", # Marketing — Okabe-Ito #3 + "#BD8233", # Operations — Okabe-Ito #4 + "#2DAE89", # Backend — lighter green "#009E73", # Frontend — base green "#007A58", # DevOps — darker green - "#F07030", # Enterprise — lighter vermillion - "#D55E00", # SMB — base vermillion - "#2090CC", # Digital — lighter blue - "#0072B2", # Brand — base blue - "#DD99C0", # HR — lighter pink - "#CC79A7", # Finance — base pink + "#D195FE", # Enterprise — lighter lavender + "#C475FD", # SMB — base lavender + "#6883B6", # Digital — lighter blue + "#4467A3", # Brand — base blue + "#CC9852", # HR — lighter ochre + "#BD8233", # Finance — base ochre ] fig = go.Figure( diff --git a/plots/survival-kaplan-meier/implementations/python/plotly.py b/plots/survival-kaplan-meier/implementations/python/plotly.py index 3fbec76e73..c2ac741422 100644 --- a/plots/survival-kaplan-meier/implementations/python/plotly.py +++ b/plots/survival-kaplan-meier/implementations/python/plotly.py @@ -45,7 +45,7 @@ def hex_to_rgba(hex_color, alpha): # Okabe-Ito palette COLOR_A = "#009E73" # First series (bluish green) -COLOR_B = "#D55E00" # Second series (vermillion) +COLOR_B = "#C475FD" # Second series (vermillion) # Data - Clinical trial with two treatment groups np.random.seed(42) diff --git a/plots/swarm-basic/implementations/python/plotly.py b/plots/swarm-basic/implementations/python/plotly.py index 59d75be1f8..ea68e6ccbd 100644 --- a/plots/swarm-basic/implementations/python/plotly.py +++ b/plots/swarm-basic/implementations/python/plotly.py @@ -23,10 +23,10 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] -FILL_COLORS = ["rgba(0,158,115,0.18)", "rgba(213,94,0,0.18)", "rgba(0,114,178,0.18)", "rgba(204,121,167,0.18)"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] +FILL_COLORS = ["rgba(0, 158, 115, 0.18)", "rgba(196, 117, 253, 0.18)", "rgba(68, 103, 163, 0.18)", "rgba(189, 130, 51, 0.18)"] # Data - student test scores across 4 classrooms with varied distributions np.random.seed(42) @@ -44,7 +44,7 @@ fig = go.Figure() for i, (classroom, scores) in enumerate(zip(classrooms, all_scores, strict=False)): - color = OKABE_ITO[i] + color = IMPRINT[i] fig.add_trace( go.Box( y=scores, diff --git a/plots/ternary-basic/implementations/python/plotly.py b/plots/ternary-basic/implementations/python/plotly.py index c04770078b..bb2c3f672e 100644 --- a/plots/ternary-basic/implementations/python/plotly.py +++ b/plots/ternary-basic/implementations/python/plotly.py @@ -18,11 +18,11 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always #009E73) -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand — primary) - "#D55E00", # vermillion (secondary) - "#0072B2", # blue (tertiary) - "#CC79A7", # reddish purple (quaternary) + "#C475FD", # vermillion (secondary) + "#4467A3", # blue (tertiary) + "#BD8233", # reddish purple (quaternary) ] # Data: Soil composition samples with meaningful clustering by soil type @@ -110,7 +110,7 @@ fig = go.Figure() # Add traces for each soil type -for soil_idx, (name, color) in enumerate(zip(["Sandy", "Silty", "Clayey", "Loam"], OKABE_ITO, strict=True)): +for soil_idx, (name, color) in enumerate(zip(["Sandy", "Silty", "Clayey", "Loam"], IMPRINT, strict=True)): mask = soil_type_indices == soil_idx fig.add_trace( go.Scatterternary( diff --git a/plots/timeline-basic/implementations/python/plotly.py b/plots/timeline-basic/implementations/python/plotly.py index ed999cc8ae..13cdf48bca 100644 --- a/plots/timeline-basic/implementations/python/plotly.py +++ b/plots/timeline-basic/implementations/python/plotly.py @@ -19,11 +19,11 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series always #009E73) -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple ] # Data - Economic and stock market milestones (2018-2024) @@ -56,12 +56,12 @@ # Color mapping for categories colors = { - "Market": OKABE_ITO[0], - "Recovery": OKABE_ITO[1], - "Crisis": OKABE_ITO[2], - "Expansion": OKABE_ITO[3], - "Growth": OKABE_ITO[0], - "Correction": OKABE_ITO[1], + "Market": IMPRINT[0], + "Recovery": IMPRINT[1], + "Crisis": IMPRINT[2], + "Expansion": IMPRINT[3], + "Growth": IMPRINT[0], + "Correction": IMPRINT[1], } # Alternate positions to prevent label overlap diff --git a/plots/timeseries-decomposition/implementations/python/plotly.py b/plots/timeseries-decomposition/implementations/python/plotly.py index edfcabb8a6..71d89da072 100644 --- a/plots/timeseries-decomposition/implementations/python/plotly.py +++ b/plots/timeseries-decomposition/implementations/python/plotly.py @@ -24,7 +24,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data: Monthly airline passengers (classic time series) np.random.seed(42) @@ -53,7 +53,7 @@ x=dates, y=ts.values, mode="lines", - line=dict(color=OKABE_ITO[0], width=2.5), + line=dict(color=IMPRINT[0], width=2.5), name="Original", hovertemplate="Original
Date: %{x|%Y-%m}
Value: %{y:.1f}", ), @@ -66,7 +66,7 @@ x=dates, y=decomposition.trend, mode="lines", - line=dict(color=OKABE_ITO[1], width=3), + line=dict(color=IMPRINT[1], width=3), name="Trend", hovertemplate="Trend
Date: %{x|%Y-%m}
Value: %{y:.1f}", ), @@ -79,7 +79,7 @@ x=dates, y=decomposition.seasonal, mode="lines", - line=dict(color=OKABE_ITO[2], width=2.5), + line=dict(color=IMPRINT[2], width=2.5), name="Seasonal", hovertemplate="Seasonal
Date: %{x|%Y-%m}
Value: %{y:.1f}", ), @@ -92,7 +92,7 @@ x=dates, y=decomposition.resid, mode="lines", - line=dict(color=OKABE_ITO[3], width=2), + line=dict(color=IMPRINT[3], width=2), name="Residual", hovertemplate="Residual
Date: %{x|%Y-%m}
Value: %{y:.1f}", ), diff --git a/plots/timeseries-forecast-uncertainty/implementations/python/plotly.py b/plots/timeseries-forecast-uncertainty/implementations/python/plotly.py index dd807a9bd7..f2a1668b58 100644 --- a/plots/timeseries-forecast-uncertainty/implementations/python/plotly.py +++ b/plots/timeseries-forecast-uncertainty/implementations/python/plotly.py @@ -17,11 +17,11 @@ ELEVATED_BG = "#FFFDF6" if THEME == "light" else "#242420" INK = "#1A1A17" if THEME == "light" else "#F0EFE8" INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" -GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" +GRID = "rgba(26, 26, 23, 0.10)" if THEME == "light" else "rgba(240, 239, 232, 0.10)" # Okabe-Ito palette COLOR_HISTORICAL = "#009E73" # Position 1 - brand green -COLOR_FORECAST = "#D55E00" # Position 2 - vermillion +COLOR_FORECAST = "#C475FD" # Position 2 - vermillion # Data generation np.random.seed(42) @@ -62,8 +62,8 @@ x=dates_forecast + dates_forecast[::-1], y=np.concatenate([upper_95, lower_95[::-1]]), fill="toself", - fillcolor="rgba(213, 94, 0, 0.10)", - line=dict(color="rgba(213, 94, 0, 0)"), + fillcolor="rgba(196, 117, 253, 0.10)", + line=dict(color="rgba(196, 117, 253, 0)"), name="95% CI", showlegend=True, hoverinfo="skip", @@ -76,8 +76,8 @@ x=dates_forecast + dates_forecast[::-1], y=np.concatenate([upper_80, lower_80[::-1]]), fill="toself", - fillcolor="rgba(213, 94, 0, 0.32)", - line=dict(color="rgba(213, 94, 0, 0)"), + fillcolor="rgba(196, 117, 253, 0.32)", + line=dict(color="rgba(196, 117, 253, 0)"), name="80% CI", showlegend=True, hoverinfo="skip", diff --git a/plots/treemap-basic/implementations/python/plotly.py b/plots/treemap-basic/implementations/python/plotly.py index 7d26b95db3..e1e23f86d1 100644 --- a/plots/treemap-basic/implementations/python/plotly.py +++ b/plots/treemap-basic/implementations/python/plotly.py @@ -20,7 +20,7 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito palette for main categories -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030"] # Data - Budget allocation by department and project (in thousands) categories = [ @@ -75,11 +75,11 @@ # Create color map using Okabe-Ito palette color_map = { "Budget": PAGE_BG, - "Engineering": OKABE_ITO[0], - "Marketing": OKABE_ITO[1], - "Sales": OKABE_ITO[2], - "Operations": OKABE_ITO[3], - "HR": OKABE_ITO[4], + "Engineering": IMPRINT[0], + "Marketing": IMPRINT[1], + "Sales": IMPRINT[2], + "Operations": IMPRINT[3], + "HR": IMPRINT[4], } # Assign colors based on category hierarchy @@ -89,7 +89,7 @@ colors.append(color_map[label]) else: parent = parents[i] - colors.append(color_map.get(parent, OKABE_ITO[0])) + colors.append(color_map.get(parent, IMPRINT[0])) # Create treemap fig = go.Figure( diff --git a/plots/venn-basic/implementations/python/plotly.py b/plots/venn-basic/implementations/python/plotly.py index 5c0b5a97f0..3330b39f23 100644 --- a/plots/venn-basic/implementations/python/plotly.py +++ b/plots/venn-basic/implementations/python/plotly.py @@ -43,8 +43,8 @@ cy = [distance * np.sin(a) for a in angles] # Okabe-Ito palette with transparency -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2"] -fill_colors = ["rgba(0,158,115,0.45)", "rgba(213,94,0,0.45)", "rgba(0,114,178,0.45)"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3"] +fill_colors = ["rgba(0, 158, 115, 0.45)", "rgba(196, 117, 253, 0.45)", "rgba(68, 103, 163, 0.45)"] hover_texts = [ f"Python
Total: {set_sizes[0]}
Only Python: {only_a}
Python ∩ JS: {only_ab}
Python ∩ SQL: {only_ac}", @@ -65,7 +65,7 @@ y=y_circle, fill="toself", fillcolor=fill_colors[i], - line={"color": OKABE_ITO[i], "width": 3}, + line={"color": IMPRINT[i], "width": 3}, mode="lines", name=set_labels[i], showlegend=False, diff --git a/plots/venn-labeled-items/implementations/python/plotly.py b/plots/venn-labeled-items/implementations/python/plotly.py index 421abd1384..ab601e9d89 100644 --- a/plots/venn-labeled-items/implementations/python/plotly.py +++ b/plots/venn-labeled-items/implementations/python/plotly.py @@ -19,8 +19,8 @@ INK_MUTED = "#6B6A63" if THEME == "light" else "#A8A79F" # Okabe-Ito categorical palette: first series is brand green -CIRCLE_COLORS = ["#009E73", "#D55E00", "#0072B2"] -CIRCLE_FILLS = ["rgba(0,158,115,0.26)", "rgba(213,94,0,0.26)", "rgba(0,114,178,0.26)"] +CIRCLE_COLORS = ["#009E73", "#C475FD", "#4467A3"] +CIRCLE_FILLS = ["rgba(0, 158, 115, 0.26)", "rgba(196, 117, 253, 0.26)", "rgba(68, 103, 163, 0.26)"] # Data: editorial Chartgeist-style commentary on tech/culture circles = [{"name": "Overhyped"}, {"name": "Actually Useful"}, {"name": "Secretly Loved"}] diff --git a/plots/violin-box/implementations/python/plotly.py b/plots/violin-box/implementations/python/plotly.py index 89c3415b11..91ece81ddf 100644 --- a/plots/violin-box/implementations/python/plotly.py +++ b/plots/violin-box/implementations/python/plotly.py @@ -26,7 +26,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette — first series is always #009E73 -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] # Data — Test scores across different teaching methods np.random.seed(42) @@ -53,14 +53,14 @@ name=group, box_visible=True, meanline_visible=True, - fillcolor=OKABE_ITO[i], + fillcolor=IMPRINT[i], opacity=0.7, line={"color": INK_SOFT, "width": 2}, points="outliers", pointpos=0, marker={"size": 8, "color": INK_SOFT, "opacity": 0.6}, box={"fillcolor": PAGE_BG, "line": {"color": INK_SOFT, "width": 2}, "width": 0.15}, - meanline={"color": OKABE_ITO[i], "width": 3}, + meanline={"color": IMPRINT[i], "width": 3}, ) ) diff --git a/plots/violin-grouped-swarm/implementations/python/plotly.py b/plots/violin-grouped-swarm/implementations/python/plotly.py index 7cbc89d1e6..6f7296294a 100644 --- a/plots/violin-grouped-swarm/implementations/python/plotly.py +++ b/plots/violin-grouped-swarm/implementations/python/plotly.py @@ -48,7 +48,7 @@ df = pd.DataFrame(data) # Okabe-Ito colors -colors = {"Novice": "#009E73", "Expert": "#D55E00"} +colors = {"Novice": "#009E73", "Expert": "#C475FD"} # Create figure fig = go.Figure() diff --git a/plots/violin-split/implementations/python/plotly.py b/plots/violin-split/implementations/python/plotly.py index 90c79f7947..b4a1250cf1 100644 --- a/plots/violin-split/implementations/python/plotly.py +++ b/plots/violin-split/implementations/python/plotly.py @@ -20,7 +20,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (first series is always #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data - Salary distributions by gender across job categories np.random.seed(42) @@ -91,8 +91,8 @@ y=subset["Salary"], name=gender, side=side, - line_color=OKABE_ITO[okabe_idx], - fillcolor=OKABE_ITO[okabe_idx], + line_color=IMPRINT[okabe_idx], + fillcolor=IMPRINT[okabe_idx], opacity=0.75, meanline_visible=True, meanline_color=INK_SOFT, diff --git a/plots/violin-swarm/implementations/python/plotly.py b/plots/violin-swarm/implementations/python/plotly.py index 0db79f22f7..dc1a1c0ef6 100644 --- a/plots/violin-swarm/implementations/python/plotly.py +++ b/plots/violin-swarm/implementations/python/plotly.py @@ -29,9 +29,9 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Colors - Okabe-Ito palette -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7"] -VIOLIN_COLOR = OKABE_ITO[0] # Bluish green -POINT_COLOR = OKABE_ITO[1] # Vermillion +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233"] +VIOLIN_COLOR = IMPRINT[0] # Bluish green +POINT_COLOR = IMPRINT[1] # Vermillion # Data - Reaction times (ms) across 4 experimental conditions np.random.seed(42) diff --git a/plots/volcano-basic/implementations/python/plotly.py b/plots/volcano-basic/implementations/python/plotly.py index ad1f7aa6ac..9f541f34ff 100644 --- a/plots/volcano-basic/implementations/python/plotly.py +++ b/plots/volcano-basic/implementations/python/plotly.py @@ -19,8 +19,8 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette -OKABE_ITO_VERMILLION = "#D55E00" # Position 2 - red/orange for up-regulated -OKABE_ITO_BLUE = "#0072B2" # Position 3 - blue for down-regulated +OKABE_ITO_VERMILLION = "#C475FD" # Position 2 - red/orange for up-regulated +OKABE_ITO_BLUE = "#4467A3" # Position 3 - blue for down-regulated # Data - Simulated differential gene expression results np.random.seed(42) diff --git a/plots/voronoi-basic/implementations/python/plotly.py b/plots/voronoi-basic/implementations/python/plotly.py index eabce1ede8..e8ac9f07f4 100644 --- a/plots/voronoi-basic/implementations/python/plotly.py +++ b/plots/voronoi-basic/implementations/python/plotly.py @@ -26,7 +26,7 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette (position 1 is brand color #009E73) -OKABE_ITO = ["#009E73", "#D55E00", "#0072B2", "#CC79A7", "#E69F00", "#56B4E9", "#F0E442"] +IMPRINT = ["#009E73", "#C475FD", "#4467A3", "#BD8233", "#AE3030", "#2ABCCD", "#954477"] # Data - Generate seed points (retail stores) within city bounds np.random.seed(42) @@ -59,7 +59,7 @@ vor = Voronoi(all_points) # Extended color palette (cycle through Okabe-Ito + supplementary colors) -extended_colors = OKABE_ITO + [ +extended_colors = IMPRINT + [ "#FF9AA2", "#FFB7B2", "#E0BBE4", @@ -149,7 +149,7 @@ x=x, y=y, mode="markers", - marker={"size": 18, "color": OKABE_ITO[0], "line": {"color": ELEVATED_BG, "width": 3}, "symbol": "circle"}, + marker={"size": 18, "color": IMPRINT[0], "line": {"color": ELEVATED_BG, "width": 3}, "symbol": "circle"}, name="Store Location", hovertemplate="Store %{pointNumber}
Latitude: %{y:.1f}
Longitude: %{x:.1f}", ) diff --git a/plots/waffle-basic/implementations/python/plotly.py b/plots/waffle-basic/implementations/python/plotly.py index edea8a65a2..28a4b6ddd4 100644 --- a/plots/waffle-basic/implementations/python/plotly.py +++ b/plots/waffle-basic/implementations/python/plotly.py @@ -19,12 +19,12 @@ GRID = "rgba(26,26,23,0.10)" if THEME == "light" else "rgba(240,239,232,0.10)" # Okabe-Ito palette - first series ALWAYS #009E73 -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple - "#E69F00", # orange + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple + "#AE3030", # orange ] # Data - Budget allocation across spending categories @@ -62,7 +62,7 @@ marker={ "size": 55, "symbol": "square", - "color": OKABE_ITO[cat_idx], + "color": IMPRINT[cat_idx], "line": {"color": PAGE_BG, "width": 2}, }, showlegend=False, @@ -77,7 +77,7 @@ x=[None], y=[None], mode="markers", - marker={"size": 22, "symbol": "square", "color": OKABE_ITO[cat_idx]}, + marker={"size": 22, "symbol": "square", "color": IMPRINT[cat_idx]}, name=f"{cat}: {val}%", showlegend=True, ) diff --git a/plots/waterfall-basic/implementations/python/plotly.py b/plots/waterfall-basic/implementations/python/plotly.py index 95b99c5ff8..e5a00d760d 100644 --- a/plots/waterfall-basic/implementations/python/plotly.py +++ b/plots/waterfall-basic/implementations/python/plotly.py @@ -24,8 +24,8 @@ # Okabe-Ito palette COLOR_POSITIVE = "#009E73" # bluish green (first series) -COLOR_NEGATIVE = "#D55E00" # vermillion -COLOR_TOTAL = "#0072B2" # blue +COLOR_NEGATIVE = "#AE3030" # imprint red +COLOR_TOTAL = "#4467A3" # blue # Data - Quarterly financial breakdown from revenue to net income categories = ["Revenue", "Product Costs", "Operating Expenses", "Marketing", "Other Income", "Taxes", "Net Income"] diff --git a/plots/windrose-basic/implementations/python/plotly.py b/plots/windrose-basic/implementations/python/plotly.py index 31dd59fdf0..2f1101e7a9 100644 --- a/plots/windrose-basic/implementations/python/plotly.py +++ b/plots/windrose-basic/implementations/python/plotly.py @@ -39,7 +39,7 @@ # Define speed bins (m/s) speed_bins = [0, 3, 6, 9, 12, np.inf] speed_labels = ["0-3 m/s", "3-6 m/s", "6-9 m/s", "9-12 m/s", ">12 m/s"] -speed_colors = ["#4A90E2", "#0072B2", "#FFD43B", "#FF9F40", "#FF5252"] +speed_colors = ["#2ABCCD", "#4467A3", "#009E73", "#DDCC77", "#AE3030"] # cyan→blue→green→amber→red # Bin the data dir_indices = np.digitize(directions, dir_bins[:-1]) - 1 diff --git a/plots/wordcloud-basic/implementations/python/plotly.py b/plots/wordcloud-basic/implementations/python/plotly.py index 177bfbb1a5..06abd9b56b 100644 --- a/plots/wordcloud-basic/implementations/python/plotly.py +++ b/plots/wordcloud-basic/implementations/python/plotly.py @@ -19,14 +19,14 @@ INK_SOFT = "#4A4A44" if THEME == "light" else "#B8B7B0" # Okabe-Ito palette (colorblind-safe) -OKABE_ITO = [ +IMPRINT = [ "#009E73", # bluish green (brand) - "#D55E00", # vermillion - "#0072B2", # blue - "#CC79A7", # reddish purple - "#E69F00", # orange - "#56B4E9", # sky blue - "#F0E442", # yellow + "#C475FD", # vermillion + "#4467A3", # blue + "#BD8233", # reddish purple + "#AE3030", # orange + "#2ABCCD", # sky blue + "#954477", # yellow ] # Data - Data science and analytics tools (distinct from programming languages) @@ -125,7 +125,7 @@ # Scale frequency to font size font_size = min_size + (freq - min_freq) / (max_freq - min_freq) * (max_size - min_size) - color = OKABE_ITO[i % len(OKABE_ITO)] + color = IMPRINT[i % len(IMPRINT)] fig.add_trace( go.Scatter( diff --git a/scripts/migrate_render_and_upload.py b/scripts/migrate_render_and_upload.py index 36a46fd166..ff7b0a6602 100644 --- a/scripts/migrate_render_and_upload.py +++ b/scripts/migrate_render_and_upload.py @@ -218,15 +218,34 @@ def render(spec: str, language: str, library: str) -> tuple[Path, Path]: # Fallback: a handful of impls save to the impl directory (script_dir) instead # of cwd — e.g. lines like `plt.savefig(os.path.join(script_dir, f"plot-{theme}.png"))`. # Move stray PNGs (and matching HTML sidecars for interactive libs) into the - # preview dir if found before checking existence. + # preview dir if found before checking existence. Skip git-tracked files — + # those are pre-existing committed artifacts shared across libraries in the + # same spec (e.g. plots//implementations/python/plot-light.html from an + # old daily-regen pass), not output from the current render. impl_dir = impl.parent for theme in ("light", "dark"): for ext in ("png", "html"): target = preview / f"plot-{theme}.{ext}" - if not target.is_file(): - stray = impl_dir / f"plot-{theme}.{ext}" - if stray.is_file(): - stray.rename(target) + if target.is_file(): + continue + stray = impl_dir / f"plot-{theme}.{ext}" + if not stray.is_file(): + continue + # Skip if git-tracked (pre-existing artifact, not our output). + try: + check = subprocess.run( + ["git", "ls-files", "--error-unmatch", str(stray)], + cwd=REPO_ROOT, + capture_output=True, + check=False, + ) + if check.returncode == 0: + continue # tracked → leave it alone + except FileNotFoundError: + # git not on PATH (very unlikely in this repo) — fall through and + # move the file as before; better than aborting the whole run. + pass + stray.rename(target) if not light_png.is_file() or not dark_png.is_file(): raise RuntimeError(f"render incomplete in {preview} — missing light or dark PNG") diff --git a/scripts/migrate_to_imprint.py b/scripts/migrate_to_imprint.py index 7b81396bb5..e425f5aae5 100644 --- a/scripts/migrate_to_imprint.py +++ b/scripts/migrate_to_imprint.py @@ -65,6 +65,19 @@ # Hex codes we expect to find — lowercased, with leading '#'. OLD_HEXES: set[str] = {k for k in COMBINED if COMBINED[k].lower() != k} +# Same mapping expressed as RGB triples, for rgba(r,g,b,a) literals. The hex +# regex above doesn't reach inline rgba() colors, but those are common in +# plotly/bokeh/altair for semi-transparent fills. Whitespace inside the rgba +# tuple is tolerated via a regex pattern rather than literal substring match. +def _hex_to_rgb(hex_str: str) -> tuple[int, int, int]: + h = hex_str.lstrip("#") + return int(h[0:2], 16), int(h[2:4], 16), int(h[4:6], 16) + + +RGB_MAP: dict[tuple[int, int, int], tuple[int, int, int]] = { + _hex_to_rgb(old): _hex_to_rgb(new) for old, new in COMBINED.items() if old.lower() != new.lower() +} + # Library names by language (subdir = language). LIBRARIES_BY_LANGUAGE: dict[str, list[str]] = { "python": ["matplotlib", "seaborn", "plotnine", "plotly", "bokeh", "altair", "pygal", "highcharts", "letsplot"], @@ -109,6 +122,34 @@ def repl(match: re.Match[str]) -> str: return new if new != original else original new_text = HEX_RE.sub(repl, text) + new_text, rgba_count = _substitute_rgba(new_text) + return new_text, count + rgba_count + + +# rgba(r, g, b, a) — r/g/b ints, a flexible. Tolerates any whitespace between +# the components and preserves the alpha + closing paren verbatim. +RGBA_RE = re.compile(r"rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,([^)]+)\)") + + +def _substitute_rgba(text: str) -> tuple[str, int]: + count = 0 + + def repl(match: re.Match[str]) -> str: + nonlocal count + r, g, b = int(match.group(1)), int(match.group(2)), int(match.group(3)) + alpha = match.group(4) + new_rgb = RGB_MAP.get((r, g, b)) + if new_rgb is None: + return match.group(0) + count += 1 + nr, ng, nb = new_rgb + # Match the source's spacing style — if the original had a space after + # the third comma, preserve it (most "well-formatted" callers do); + # otherwise stay compact. Avoids ending up with mixed "a, b, c,d" output. + alpha_str = alpha if alpha.startswith(" ") else " " + alpha.lstrip() + return f"rgba({nr}, {ng}, {nb},{alpha_str})" + + new_text = RGBA_RE.sub(repl, text) return new_text, count @@ -163,8 +204,12 @@ def _process_file( original = impl_path.read_text() lower = original.lower() - has_old = any(h in lower for h in OLD_HEXES) - if not has_old: + has_old_hex = any(h in lower for h in OLD_HEXES) + has_old_rgba = bool(RGBA_RE.search(original)) and any( + f"rgba({r},{g},{b}" in lower.replace(" ", "") or f"rgba({r}, {g}, {b}" in original + for r, g, b in RGB_MAP + ) + if not (has_old_hex or has_old_rgba): stats.skipped_already_imprint += 1 return