Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
色彩雫
I just discovered that the R script I had written while back, which was a hand-curated colour palette of Pilot Iroshizuku fountain pen inks.
Pilot describes Iroshizuku as a combination of iro = colour, and shizuku = droplet. The individual inks take their names from Japanese landscapes, plants, seasons, and other bits of nature.
The names don’t simply tell you what colour an ink is.
- 月夜 isn’t just dark blue. It is moonlit night.
- 花筏 isn’t just pink. It evokes cherry blossom petals floating together on water like a little raft.
- 冬将軍 – literally the Winter General – somehow becomes a cool gray.
So naturally, I turned them into data!
< section id="the-data" class="level2">The data
This is a small hand-curated dataset of 24 Iroshizuku inks. The hex colours are approximate representations rather than measurements of the physical inks. Fountain pen ink is much more complicated than a single hex value: paper, nib width, saturation, shading, sheen, and lighting all change how an ink appears.
The ink names and descriptions are based on Pilot’s Iroshizuku collection. The hex values are approximate colours used for this visualization rather than official measured colour values.
But hex is enough for a little plotting experiment!
< section id="first-just-the-colours" class="level2">First: just the colours
Before making bottles, it is useful to see the palette itself.
This already makes a nice colour chart, but the ordering feels fairly arbitrary. So I wanted to see what would happen if the inks were arranged by colour rather than by catalogue order.
< section id="sorting-colours-perceptually" class="level2">Sorting colours perceptually
RGB is useful for screens, but it isn’t especially good at representing how humans perceive differences between colours. For sorting this palette, I converted the hex values into HCL colour space using the colorspace package.
HCL separates colour into:
- Hue — roughly which colour family it belongs to
- Chroma — how colourful or saturated it feels
- Luminance — how light or dark it appears
That makes it much nicer for arranging colours in a visually coherent sequence.
hcl_coords <- coords(
as(hex2RGB(iroshizuku_colors$hex), "polarLUV")
) |>
as_tibble()
ink_plot <- iroshizuku_colors |>
bind_cols(hcl_coords) |>
mutate(
# Rotate the hue wheel so the sequence starts near blue / teal.
hue_sort = (H - 220) %% 360
) |>
arrange(hue_sort, desc(L), desc(C)) |>
mutate(
plot_order = row_number() - 1,
col = plot_order %% 6,
row_raw = plot_order %/% 6,
row = max(row_raw) - row_raw
)
The exact order is not scientifically important. I rotated the hue wheel so that the display begins around the blue-green part of the palette, simply because it produces a calmer visual flow for this particular set of inks.
< section id="the-tiny-ink-shop" class="level2">The tiny ink shop
I wanted the palette to look like a tiny Japanese stationery-shop display: rows of ink bottles, wooden shelves, paper labels, and little price cards.
The whole thing is still just ggplot2.
The palette as data
And because this is still a data project, here is the resulting palette in the same perceptual order.
| 日本語 | Ink | Meaning | Hex | Hue ° | Chroma | Lightness |
|---|---|---|---|---|---|---|
| 月夜 | Tsukiyo | Moonlit Night | #016D8C | 228 | 44.5 | 42.5 |
| 立夏 | Rikka | Early Summer | #1A7DA5 | 233 | 52.4 | 49.0 |
| 冬将軍 | Fuyusyogun | Winter Commander | #6A869A | 233 | 24.5 | 54.5 |
| 天色 | Amairo | Sky Blue | #00A0DF | 237 | 76.5 | 62.1 |
| 紺碧 | Konpeki | Deep Cerulean Blue | #0368B4 | 250 | 74.5 | 43.1 |
| 深海 | Shinkai | Deep Sea | #1C3A65 | 253 | 36.9 | 24.4 |
| 紫陽花 | Ajisai | Hydrangea | #1255A2 | 254 | 70.0 | 36.4 |
| 朝顔 | Asagao | Morning Glory | #04318E | 261 | 67.8 | 24.2 |
| 紫式部 | Murasakishikibu | Murasaki Shikibu | #765FA8 | 276 | 56.5 | 45.4 |
| 竹炭 | Takesumi | Bamboo Charcoal | #1E1D1E | 308 | 0.6 | 10.9 |
| 山葡萄 | Yamabudo | Wild Grape Vine | #660D5B | 317 | 47.2 | 23.2 |
| 花筏 | Hanaikada | Floating Cherry Blossoms | #ED7E93 | 2 | 74.6 | 65.8 |
| 紅葉 | Momiji | Autumn Maple Leaves | #E12E2C | 12 | 140.0 | 49.7 |
| 春暁 | Syungyo | Spring Dawn | #674F4D | 17 | 15.5 | 36.0 |
| 冬柿 | Fuyugaki | Winter Persimmon | #EA5A10 | 22 | 128.0 | 56.9 |
| 夕焼け | Yuyake | Sunset Glow | #EF881F | 35 | 104.2 | 66.6 |
| 山栗 | Yamaguri | Wild Chestnut | #5B4532 | 45 | 21.2 | 31.1 |
| 灯籠 | Toro | Lantern Light | #F0B018 | 55 | 92.7 | 75.9 |
| 蛍火 | Hotarubi | Firefly Glow | #D9DA26 | 86 | 89.9 | 84.5 |
| 竹林 | Chikurin | Bamboo Forest | #94BD4E | 107 | 68.9 | 71.7 |
| 深緑 | Shinryoku | Forest Green | #007E4F | 145 | 48.9 | 46.3 |
| 松露 | Syoro | Dew on Pine Tree | #077D5E | 156 | 41.9 | 46.3 |
| 翠玉 | Suigyoku | Emerald | #037261 | 169 | 35.1 | 42.6 |
| 孔雀 | Kujaku | Peacock | #028986 | 189 | 40.4 | 51.4 |
I started with an old R script containing 24 fountain pen colours.
Somewhere along the way I learned a little more about perceptual colour spaces and built a tiny imaginary Japanese ink shop out of geom_rect().
Now I just want more ink. 🖋️
< !-- -->R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
