Radiation from a quasi-periodically modulated electron beam