Statistical Inference After Adaptive Sampling for Longitudinal Data