timewriter: Time protocol writer

Description Usage Arguments Details Value


Creates and collates time protocol data given minimal information (light pattern and protocol steps)


timewriter(lit, prot, sec3 = 0)



a boolean or 0-1 integer vector indicating frames with lights on or off


a list of protocol steps, in order; it can contain 0's and 1's, but only 2-5 are actually used


an optional section 3 add-on to stick the last 2s back onto the protocol (input in frames!!!)


Protocol steps are assumed to follow the scheme:

This is primarily for the collapse of 4 and 5 into a single chunk.

There is currently no data cleanup. The underlying noise therefore shows up in frame variability (~4 frame jitter).


A data frame containing the columns time (frame number), lit (lights on or off, 0-1 integer), chunk (broad section definer including on frames and surrounding off frames), section (narrow section definer attributing values to each on and off time separately), rept (repeat: used in conjunction with section to uniquely identify each lights-on event) and various timers centered at the appropriate light-on time (chunktimer, sectiontimer, and lighttimer).

PaolaCognigni/CTraxHelper documentation built on May 7, 2019, 11:57 p.m.