[R] Teaching R - In front of the computer?

(Ted Harding) Ted.Harding at nessie.mcc.ac.uk
Mon Sep 19 19:36:41 CEST 2005

On 19-Sep-05 Rau, Roland wrote:
> Dear R-Users,
> given you have been teaching R to students (grad level, mainly
> social science background, no previous programming experience,
> 80% know SPSS),what are your experiences concerning the style
> of teaching? Do you prefer to stand in front of the class like
> in "normal" lectures and you show them slides? Or do you you
> explain some concept (for example things like mydata[order(var1,
> var2),]) and show it directly on the computer via beamer/projector
> and also the students have to enter it on the computers in front
> of them.
> Any experiences you can share are highly appreciated.
> Thanks,
> Roland

I'd like to suggest (perhaps more for discussion than for
implementation) thinking of the use of 'xmx' ("X MultipleXer").


This work in X Windows on Unix/Linux. The essence of it is that
the software is installed on each of a group of networked computers.
One of these is the "master", who starts it up in "Floor" mode
and nominates any or all of the others to be in "Floor", "Seat"
or "View" mode (terminilogy apparently inspired by what happens
at meetings).

This causes an W window to appear on all nominated computers,
within which is running a virutal X session. Anyone with "Floor"
rights can do anything in that session, and it will be mirrored
to all others. This includes keyboard input and mouse movements.
Anyone in "View" mode an only see what is going on, but cannot
make any input. In "Seat" mode, a user can virtually "raise their
hand" and be granted "Floor" privileges.

Anything anybody does outside the XMX window is private to them,
and will not be seen by others, nor have any effect on the XMX

This software seems not to have undergone further development
in its public form for some time (apparently June 1999). I don't
know if there have been further developments in a private or
proprietary form.

Its creator, John Bazik at Brown University, states that "Xmx
provides reasonable real-time performance on a local 10 Mb/sec
ethernet on 52 UltraSparc-class machines."

It might well provide a good vehicle for expository teaching
in a class that large, since each student can see on their
own screen what the instructor is displaying (and this could
include a "slide-show" presentation alongside code files,
commands being run in an R window, graphics plots, etc.).

However, you would not want a class that size to all be in
"Floor" mode! "Seat" mode could be OK, though, since anyone
who wants to ask a question can go into "Floor" and then thsy
can input things into the XMX session, or even just move their
mouse around to indicate what they are talking about -- something
which in a normal class could only be done by coming out to the

I have used it for teaching on a much smaller scale -- tutorial
sessions with 1 or 2 others, where everyone can be in "Floor"
mode and can make their own spontaneous changes to what's ging
on without any bureaucracy. This can include having everyone
participate in editing a file of R commands, so that everyone
can see what the effect of doing this or that is. I have found
it to work well, and to be appreciated by students.

This mode could work with more than 1 or 2 students.

The main snag with using XMX is that the X display must be the
same on all machines. This was a deliberate design implementation,
since it cuts down enormously on network traffic. However, it
does mean that all machines must have a sufficiently large overlap
in X resouces (i.e. as reported by 'xdpyinfo').

The resources don't have to be absolutely identical, but certainly
colour-depths must be the same all round, and in my experience
you had better have the same display geometry (e.g. 1280x1024),
and there are various other things. One way to find out is to
start it up nominating all the participating machines at once.
If there's a compatible sufficient overlap, it will work.

However, in a teaching Lab with all the machines the same, it
should be straightforward to get it going.

One nice thing about doing things this way is that a student
could be running a private R session alongside the public XMX
one, and copy&paste from the public one into the private one
(or vice versa). They could also be running an editor session
to write their own course notes.

Anyway, there it is if you hadn't heard of it.

Best wishes to all,

E-Mail: (Ted Harding) <Ted.Harding at nessie.mcc.ac.uk>
Fax-to-email: +44 (0)870 094 0861
Date: 19-Sep-05                                       Time: 18:36:32
------------------------------ XFMail ------------------------------

More information about the R-help mailing list