Advanced Data Visualization – 001 | Lesson 03 — Perception, Preattentive Attributes, Colour and Visualization Ethics

AI-GENERATED COURSE CONTENT — PUBLISHED AS IS. This new lesson is AI-generated, based on questions and topic collections from Open Education, including source articles attributed to Sayed Ahmed where indicated. The new AI-generated prose, original synthetic-data plots and original code are offered for reuse without copyright restrictions asserted by this site. Third-party references have separate rights. AI can make mistakes; independently check code, statistics, and interpretations.

Course: Advanced Data Visualization – 001 — course syllabus. Original source posts: Post 16171 · Post 16059 · Post 76547.

Learning focus. Human perception determines what a viewer notices first. Position and aligned length are usually easier to compare precisely than area, angle or arbitrary 3D volume. Accessibility requires more than a pleasing colour palette.

Original illustrative visualization: Perception, Preattentive Attributes, Colour and Visualization Ethics.
Original course-created illustrative plot using synthetic observations. Follow the code below to create your own figure.

Theory and algorithmic reasoning

Preattentive cues include position, orientation, size, shape and contrast. Prefer consistent encoding: colour for category, sequential luminance for ordered magnitude, diverging scales for values around a meaningful midpoint, and text labels where exact numbers matter.

Avoid truncated baselines on bar charts, rainbow colours for ordered values, unannounced log scales, misleading area size, and red–green-only differences. Distinguish exploratory displays from persuasive infographics and explain exclusions.

Mathematical ideas

Weber’s law is a perceptual approximation: ΔI/I≈k for a just-noticeable difference under restricted conditions. It is not a universal chart-accuracy formula.

Python: Reproducible plot

import matplotlib.pyplot as plt
items=["A","B","C"];v=[98,100,102]
fig,axes=plt.subplots(1,2,figsize=(9,3.6))
for ax in axes:
    ax.bar(items,v)
    ax.set_title("Baseline matters")
axes[0].set_ylim(0,110)
axes[1].set_ylim(95,105)
axes[1].set_title("Truncated: exaggerates difference")
for ax in axes: ax.set_ylabel("Score")
plt.tight_layout();plt.show()

R: Reproducible plot with ggplot2

library(ggplot2)
df <- data.frame(group=c("A","B","C"),score=c(98,100,102))
ggplot(df,aes(group,score)) +
  geom_col(fill="#3777a5") +
  coord_cartesian(ylim=c(0,110)) +
  labs(title="Show the zero baseline",y="Score") +
  theme_minimal()
# Avoid coord_cartesian(ylim=c(95,105)) on bars
# unless the truncation is explicitly justified.

Expected output and interpretation

The values 98, 100, 102 differ by only four units, yet a truncated baseline can make them look dramatically different. The two graphics use identical data; only the vertical scale changes.

Questions and answers

Q1. Why is a rainbow colormap often a bad choice for magnitude?

Answer. It introduces uneven perceptual steps and artificial boundaries; a monotonic-luminance sequential map is usually easier to interpret.

Q2. Which channel is suitable for precise comparisons?

Answer. Aligned position on a common numerical scale is typically strongest, followed by length.

Q3. What should accessibility testing cover?

Answer. Colour-vision differences, contrast, labels, keyboard interaction, text alternatives, screen-reader content and motion.

Assessment and practical exercise

Redesign a misleading bar chart. Explain how your new colour, baseline, labels and accessible alternative improve interpretation.

Translated to Bengali / বাংলায় অনুবাদ

বাংলা অনুবাদ: এই পাঠের ব্যাখ্যামূলক লেখা ও প্রশ্নোত্তরের সহজ, যথাযথ বাংলা অনুবাদ নিচে দেওয়া হলো। Python ও R কোড অপরিবর্তিত রয়েছে; উপরের কোড চালিয়ে চার্ট তৈরি করুন।

শেখার বিষয়: মানুষের দৃষ্টিগ্রাহ্যতা নির্ধারণ করে কোন তথ্য আগে নজরে পড়বে। অবস্থান ও দৈর্ঘ্যের তুলনা সাধারণত ক্ষেত্রফল, কোণ বা ৩-মাত্রিক আয়তনের তুলনায় নির্ভুল। সুন্দর রং ব্যবহার করাই যথেষ্ট নয়—সহজপাঠ্যতাও জরুরি।

দ্রুত চোখে ধরা পড়া সংকেতগুলোর মধ্যে অবস্থান, দিক, আকার ও বৈসাদৃশ্য রয়েছে। শ্রেণির জন্য আলাদা রং, ক্রমযুক্ত মানের জন্য উজ্জ্বলতার ক্রম এবং কেন্দ্রিক পার্থক্যের জন্য দুইমুখী রঙের স্কেল ব্যবহার করা ভালো।

বার চার্টের শূন্য ভিত্তি অকারণে বাদ দেবেন না, ক্রমযুক্ত মানে রংধনু স্কেল ব্যবহার এড়িয়ে চলুন, লগ স্কেল স্পষ্ট করুন এবং শুধু লাল-সবুজের পার্থক্যে ভরসা করবেন না। উপাত্ত বাদ দিলে কারণ জানাতে হবে।

গাণিতিক ধারণা: ওয়েবারের সূত্র একটি উপলব্ধিগত আনুমানিক সম্পর্ক: নির্দিষ্ট পরিবেশে ΔI/I≈k। এটি সব চার্টের নির্ভুলতা মাপার সার্বজনীন সূত্র নয়।

প্রত্যাশিত ফল: ৯৮, ১০০ ও ১০২-এর পার্থক্য মাত্র চার। কিন্তু উল্লম্ব অক্ষ ৯৫ থেকে শুরু করলে ব্যবধান অনেক বড় মনে হতে পারে। উভয় চার্টের উপাত্ত একই, শুধু স্কেল আলাদা।

প্রশ্ন 1. পরিমাণ বোঝাতে রংধনু রঙের স্কেল কেন ঝুঁকিপূর্ণ?

উত্তর: বিভিন্ন রঙের দৃশ্যগত দূরত্ব সমান নয়; ফলে ভুল সীমারেখা বা পার্থক্য মনে হতে পারে।

প্রশ্ন 2. সুনির্দিষ্ট তুলনার জন্য কোন দৃশ্য সংকেত ভালো?

উত্তর: একই সংখ্যাগত অক্ষে অবস্থান সবচেয়ে কার্যকর; এরপর দৈর্ঘ্য।

প্রশ্ন 3. সহজপ্রবেশযোগ্যতা পরীক্ষায় কী দেখবেন?

উত্তর: রঙের পার্থক্য, কনট্রাস্ট, লেবেল, কিবোর্ড ব্যবহার, বিকল্প লেখা ও নড়াচড়ার প্রভাব।

বাংলা অনুশীলন

বিভ্রান্তিকর একটি বার চার্ট নতুন করে নকশা করুন। রং, শূন্যভিত্তি, লেবেল ও বিকল্প বর্ণনার উপযোগিতা ব্যাখ্যা করুন।

উৎস ও ব্যবহার: মূল লেখাগুলোর লিংক উপরে দেওয়া আছে। নতুন এআই-তৈরি ব্যাখ্যা ও নিজস্ব নমুনা-চিত্র পুনর্ব্যবহারযোগ্য; বাহ্যিক উৎসের স্বত্ব আলাদা। এআই ভুল করতে পারে, তাই ফল যাচাই করুন।


Discover more from Open Education

Subscribe to get the latest posts sent to your email.

Leave a Reply

Discover more from Open Education

Subscribe now to keep reading and get access to the full archive.

Continue reading