Generate a single pulse, either a Dirac pulse (Dirac delta) or a square pulse.
pulse(
type = "dirac",
leading = 22050,
pulse.length = 1,
duration = samp.rate,
samp.rate = 44100,
bit = 1,
pcm = FALSE,
stereo = FALSE,
output = "Wave",
invert = FALSE
)
Specified by output.
Either "dirac" or "square".
The number of samples before the pulse.
The number of samples in the pulse (for "square").
The total number of samples generated.
The sample rate.
The bit depth.
Whether Wave generated is PCM (see tuneR).
Whether Wave generated is stereo.
The output format ("Wave").
Whether to invert the pulse.