Interactive visualizations

(MMG640 / MVE080)

Overview

  • Why interactive plots?
  • What is a GUI?
  • Some history
  • Building GUI in MATLAB
  • What is a callback function?
  • Interactivity on the web: HTML5 + CSS + javascript + d3

Why interactive plots?

Static images (printing tradition)

Animations

Interactive visualizations

 

  • learning
  • knowledge
  • insight
  • data exploring

Example: Bezier curves

What is a GUI?

Interactive visualization =

GUI + dynamically changing visualization

Not a GUI: example of text based user interface

History of GUIs

Origin of today's GUI:

XEROX Alto 1973

Popularized by Apple:

Macintosh 128k 1984

today

Microsoft Windows,

X-windows,

"button" mobile phones,

Iphone (touch devices)

Create GUI in MATLAB

GUIDE: GUI for building GUIs

How does the interface know what to do?

Callback functions

What happens when you press a button?

Main

event loop

Enter program

Event triggered

Registered callback

evaluated

Examples of events:

  • onMouseOver
  • onMouseDown
  • onMouseClick
  • onKeyDown
  • ...

Exercise: GUI in MATLAB

Login to Canvas and start working with

Exercise: Simple GUI in MATLAB