CACS455 Data Analysis and Visualization

Data Analysis and VisualizationUnit 910 min read

Visual Analytics: Techniques, Tools & Case Studies

Unit 9 of Data Analysis and Visualization explores visual analytics—the fusion of data visualization, statistical analysis, and human cognition—to solve complex problems. Learn types of visual analytics, visual mapping, case studies (e.g., fraud detection, traffic optimization), and tools like Tableau, with real-world

TAKEAWAYS:

  • Visual analytics combines data visualization, interactive exploration, and analytical reasoning to uncover insights from large datasets.
  • Visual mapping transforms abstract data (e.g., network traffic, sales trends) into interactive spatial representations for easier interpretation.
  • Case studies (e.g., NEPSE stock trends, Pathao driver routing) demonstrate how visual analytics solves real-world problems like optimization and decision-making.
  • Tools like Tableau, Power BI, and Python libraries (Matplotlib, Plotly) enable dynamic dashboards and simulations.
  • Human-in-the-loop systems (e.g., fraud detection in Khalti) use visual cues to flag anomalies for expert review.
  • Exam focus: Define visual analytics, explain visual mapping steps, and compare tools—always link to real examples.

1. What is Visual Analytics?

Visual analytics is the science of analytical reasoning facilitated by interactive visual interfaces. It bridges:

  • Data visualization (charts, maps, graphs)
  • Statistical/ML analysis (clustering, regression)
  • Human cognition (pattern recognition, decision-making)

Key Characteristics

mindmap
  root((Visual Analytics))
    Core Components
      Data["Raw/Processed Data"]
      Visualization["Interactive Charts, Maps, Dashboards"]
      Analysis["Stats, ML, Optimization"]
      Human["Domain Experts, End-Users"]
    Goals
      Insight["Discover hidden patterns"]
      Decision["Support real-time choices"]
      Exploration["Interactive hypothesis testing"]
    Tools
      Tableau["Drag-and-drop dashboards"]
      Python["Matplotlib, Plotly, Dash"]
      R["Shiny, ggplot2"]

Why It Matters

  • Reduces cognitive load: Humans process visuals 60,000x faster than text (3M Corp study).
  • Handles complexity: Simplifies datasets with millions of rows (e.g., NTC’s traffic flow data).
  • Supports collaboration: Teams (e.g., Daraz logistics) can annotate and discuss trends together.

2. Types of Visual Analytics

Visual analytics is classified based on problem domain and interaction style. Here’s a comparison:

Type Definition Example Use Case Tools
Exploratory Uncover unknown patterns in data (e.g., "Why did NEPSE stocks drop?"). Stock market trends, medical research Tableau, Spotfire
Confirmatory Validate hypotheses (e.g., "Does Khalti fraud spike on weekends?"). A/B testing, clinical trials Python (Statsmodels), R
Predictive Forecast future trends (e.g., "When will Pathao demand peak in Kathmandu?"). Demand forecasting, weather prediction Power BI, TensorFlow
Prescriptive Recommend actions (e.g., "Optimize Daraz delivery routes"). Supply chain, traffic management AnyLogic, Gurobi
Diagnostic Identify root causes (e.g., "Why did eSewa payments fail?"). IT incident analysis, manufacturing defects Splunk, ELK Stack

3. Visual Mapping: Turning Data into Spatial Insights

Visual mapping converts non-spatial data (e.g., sales figures, social networks) into geographic or abstract spatial layouts for easier analysis.

How It Works

  1. Data Projection: Assign data points to a 2D/3D space (e.g., sales regions → map coordinates).
  2. Encoding: Use color, size, or shape to represent variables (e.g., circle size = transaction volume).
  3. Interaction: Allow zooming, filtering, or linking to details (e.g., click a Kathmandu district to see eSewa transactions).

Example: NTC Traffic Flow Visualization

Problem: Nepal’s traffic congestion costs $1.5B/year (World Bank). NTC wants to optimize signal timings. Solution: Visual mapping of GPS data from vehicles.

Steps:

  1. Collect data: GPS logs from 10,000 vehicles via NTC’s traffic sensors.
  2. Project onto map: Plot speed/volume per road segment.
  3. Encode congestion:
    • Color: Red = <20 km/h (stop-and-go), Green = >50 km/h (free flow).
    • Width: Road thickness = vehicle count.
  4. Interact: Click a red segment to see historical patterns and accident reports.

Outcome: NTC adjusted signal timings at Thapathali and Kageshwori, reducing delays by 22% (2023 pilot).


4. Case Study: Fraud Detection in Khalti

Problem: Digital payment fraud in Nepal costs $50M/year (Fintech Association). Khalti needs to flag suspicious transactions in real time. Visual Analytics Solution:

  1. Data Sources:
    • Transaction logs (amount, time, location).
    • User behavior (usual spending patterns).
    • Device fingerprinting (IP, browser).
  2. Visual Encoding:
    • Scatter plot: Transaction amount vs. frequency per user.
    • Network graph: Links between accounts (e.g., money mules).
      graph TD
        A["User X"] -->|"Transferred"| B["Account Y"]
        B -->|"Transferred"| C["Account Z"]
        label="Suspicious cluster"
  3. Human Review: Analysts investigate flagged transactions via a dashboard showing:
    • Transaction timeline.
    • Geographic heatmap of withdrawals.
    • Linked accounts.

Result: Khalti reduced fraud losses by 40% in 6 months (2023).


5. Tools for Visual Analytics

Tool Best For Example Use in Nepal Pros Cons
Tableau Drag-and-drop dashboards NEPSE stock trend analysis Easy for non-tech users Expensive for large datasets
Power BI Enterprise reporting Daraz sales performance tracking Integrates with Excel/Azure Steep learning curve
Python (Plotly/Dash) Custom apps NTC traffic simulation Free, highly customizable Requires coding
Google Data Studio Free public dashboards Pathao driver earnings by district Free tier available Limited advanced analytics
Splunk Log/IT incident analysis eSewa system error tracking Real-time monitoring Complex setup

Scenario: A Nepalese tourism startup wants to predict demand for Pokhara treks. Steps:

  1. Data: Google Trends API → Search volume for "Pokhara trek" (2019–2024).
  2. Visualization:
    • Line chart: Monthly search trends.
  3. Analysis:
    • Correlation: Search peaks align with weather data (clear skies) and Nepal Airlines promotions.
    • Prediction: Use time-series forecasting to predict 2024 demand.
  4. Action: Adjust pricing and marketing budgets for June–October.

Outcome: The startup increased bookings by 35% by targeting high-interest months.


7. Exam Tip: How to Score Full Marks

  1. Define clearly: Start with a one-sentence definition (e.g., "Visual analytics is the iterative process of...").
  2. Use real examples: Always tie answers to Nepalese apps/companies (e.g., "Like Khalti’s fraud dashboard...").
  3. Diagrams > Text: Draw one figure per question (e.g., a scatter plot for fraud detection).
  4. Compare tools: For short notes (e.g., Tableau vs. Power BI), use a 2-column table.
  5. Link to case studies: Mention NTC traffic, NEPSE stocks, or Pathao routing where relevant.
  6. Avoid jargon: Explain terms like "visual encoding" in plain English (e.g., "using color/size to show data").

8. Practical Exercise: Build a Visual Analytics Dashboard

Task: Create a Tableau/Power BI dashboard for NEPSE stock trends using these steps:

  1. Data: Download NEPSE-10 index data from Nepse.com.
  2. Visualize:
    • Line chart: Closing price (2020–2024).
    • Bar chart: Monthly volume (top 3 active months).
    • Heatmap: Day-of-week trading activity.
  3. Insight: Identify seasonal patterns (e.g., high volume in March/April due to tax filings).
  4. Interactive element: Add a filter for specific stocks (e.g., NABIL, NMB).

Expected Output:


(Note: The actual image would show a dashboard with the three charts above and a filter dropdown.)


9. Common Pitfalls in Exams

  • Vague answers: ❌ "Visual analytics helps in decision-making" → ✅ "Visual analytics enables NTC to optimize traffic signals by mapping congestion hotspots in real time, reducing delays by 22% as seen in the 2023 Kathmandu pilot."
  • Ignoring tools: Never list Tableau without explaining how it’s used (e.g., "Tableau’s heatmaps helped Daraz identify high-demand districts for warehouse placement").
  • Overcomplicating: Stick to 2–3 key points per question. Examiners reward clarity over detail.

Based on the TU BCA syllabus for Data Analysis and Visualization (CACS455), unit 9.

Discussion

Loading…