I'm attempting to create a sequence for an experiment and am hoping I can
use R to create it. It has several constraints:

(1) It is made up of two sequences (red and green) that have 4 different
repeating triplets (e.g. T1=ABC T2=DEF T3=GHI JKL)
(2) Each sequence has the following constraints: (a) there cannot be
repeating triplets (e.g. T1 T1), (b) there cannot be repeating triplet
pairs (e.g. T1 T2 T1 T2)
(3) Triplets occur with the following frequency: T1=20, T2=23, T3=26, T4=36
(same for red and green sequences)
(4) Red and green sequences are then interleaved, such that you never get
more than 6 in a row of one color.

(For those that are interested, I'm trying to replicate Turke-Browne,
Junge, & Scholl, 2005, *JEP*, but with frequency manipulations to the
triplets)

Thanks in advance for any help.

	[[alternative HTML version deleted]]

