Added script for recording spontaneous activity.
Improved Rin script.