various scripts used by the princelab for data processing