Accelerometer sampling rate

I am using an ADXL335 Accelerometer with my Arduino Uno R3. Datasheet of the sensor linked to the name.

I am trying to calculate tap velocity using the set up. My integration code is working fine, or atleast seems like it is given the snappy and discrete nature of the application. I have coded to stop integrating as soon as a tap is completed, i.e. inertial acceleration goes back to 0 to negative, as accelerator moves up in natural bounce motion. And the final velocity is recorded separately before being reverted back to 0.

But, the problem is... it's not recording every sample. It records the velocity, seemingly accurately for one tap... takes a long time, missing several samples in between. I have also noticed that only after I set the accelerometer at initial state of parallel to ground, it records the next sample or tap.

Ideally, I want it to atleast record 6 samples per second. How do I go about fixing this?

Based on your code you are using analogRead() which waits for the sample then runs the rest of your program. The ISR method of reading the ADC, allows the samples to be read as soon as they are ready and another sample to be started immediately.

Try the asynchronous ADC read

Thank you! That should theoretically solve the issues. Although, I am not able to understand a couple of processes. Would you mind explaining the "why and how" of these processes if I quote them here?
Edit: And yes, I am/was using analogRead().