plyForEach
  1. factor
  2. func

The plyForEach function repeats each event the given number of times, applying the given function to each event. This version of ply uses the iteration index as an argument to the function, similar to echoWith.

"<0 [2 4]>"
.plyForEach(4, (p,n) => p.add(n*2))
.scale("C:minor").note()

aliases: plyforeach()

parametertype
factor
  • number
how many times to repeat
func
  • function
function to apply, given the pattern and the iteration index