0

I'm trying to change the color of the animation token based on a column value of the data.

The idea is if we have the first character in the first column value as "n", we have one colour, or "b" its a different color.

This is the code we currently use for animation :

animate_process(the_output,mode = "relative", jitter=10, legend = "color",mapping= token_aes(color = token_scale("column1", scale = "ordinal",range = RColorBrewer::brewer.pal(12, "Paired")))) 

Any help appreciated.

steve
  • 395
  • 2
  • 11

0 Answers0