Chaos Game Representation

We recently developed an R package kaos, which can be used to build fractals from sequences of symbols. These fractals are based on the Chaos Game Representation (CGR), which is a recurrent iterative function system. While CGR has been used mainly for genome sequence encoding and classification in the context of bioinformatics, we modified it to work also for protein sequences, resulting in n-flakes representation, an image with several icosagons (Löchel et al., 2019). In fact, our implementation can be used with any kind of alphabets, including for instance DNA, proteins, but also other alphabets such ASCII or simple numbers. By modifying the color scale for the frequency matrix CGR, it is even possible to create beautiful images of these sequences, see e.g., the FCGR of π.

Figure 1: π as an FCGR image.

Written by: Heider