index adjusted to be 0-indexed
specify that peaks are integers