Try this code in Audacity’s Nyquist Prompt …
(setq mysound s)
(setq q 50) ; set the base Q for the filter
(setq iter 20) ; set the number of iterations
(setq freq 1000) ; set base frequency
; start the DO loop
(dotimes (i iter mysound)
(setf mysound (notch2 mysound (* freq (1+ i)) (* q (1+ i))))
) ;end of loop
It will look like this …