Append a list to itself N times.

Evan Chandler's icon

I have a list of 5 numbers (filter coefficients being generated by a filtergraph~). Let's say for example it's "0.1 0.2 0.3 0.4 0.5".

cascade~ sees the first 5 numbers of an incoming list as filter 1, the next 5 numbers as filter 2 etc..
So if I had a list of 10 numbers like this "0.1 0.2 0.3 0.4 0.5 0.1 0.2 0.3 0.4 0.5" I would have 2 filters that are exactly the same.

I'd like to be able to take a list and then append it to itself N times so that I can duplicate one set of filter coefficients N times in cascade~.

I realize that filtergraph~ can output a list of filter coefficients for 24 filters but I'd prefer to be able to use filtergraph~ to make one set of coef's and dupicate the list as many times as I like.

Is this possible without the use of uzi? I saw someone using a jitter scanwrap thing but I'm not sure how that stuff works.

Roman Thilenius's icon

for a fixed number of filters... send the list into input #1 and #6 of a [pack 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. ]

double_UG's icon

thresh

Max Patch
Copy patch and select New From Clipboard in Max.

Exit Only's icon

whats wrong with uzi? here is a patch that should do what you want.

Max Patch
Copy patch and select New From Clipboard in Max.

Roman Thilenius's icon


110.cloner does it, but for lists you had to multiply the amount argument with the list length. (i.e. N*5 in your case)
https://cycling74.com/forums/create-a-list-of-clones-values

Evan Chandler's icon

Thanks so much everyone for your help. Double UG & Nick Inhofe, these patchers work great. I am not sure what I thought the problem was with uzi. I guess I thought it wouldn't be fast enough or I thought maybe it was kinda a janky way to do it but it actually works perfectly.

Roman, the cloner thing you linked looks like it would work as well but it seems to be using the same ideas as the patchers the others linked. Thanks.

I guess I thought there would be a more elegant way to achieve this like some kind of duplicate object or something but it seems like the uzi is the answer.