I will present results from two studies in functional and longitudinal data analysis and time-varying effects modeling. The novel methodologies are applied to understand implicit learning in children with autism spectrum disorder (ASD) and to modeling cardiovascular (CV) outcome over time in patients on dialysis. The first study is on neural correlates of implicit learning in young children with ASD and involves the analysis of electroencephalogram (EEG) data. Differential brain response to sensory stimuli is very small (a few microvolts) compared to the overall magnitude of spontaneous EEG, yielding a low signal-to-noise ratio in event-related potentials (ERP). To cope with this phenomenon, stimuli are applied repeatedly and the ERP signals arising from the individual trials are averaged at the subject level. This results in loss of information about potentially important changes in the magnitude and form of ERP signals over the course of the experiment. I will describe a new meta-preprocessing step utilizing a moving average of ERP across sliding trial windows to capture such longitudinal trends. This procedure is embedded in a weighted linear mixed effects model and a robust functional clustering model to describe longitudinal trends in ERP features. Results provide insights about the mechanisms underlying social and/or cognitive deficits in children with ASD. The second study is on modeling time-varying risk factors associated with cardiovascular diseases in patients on dialysis. Cardiovascular disease and infection are leading causes of hospitalization and death in the dialysis population. Although recent studies have found that the risk of CV events is higher after an infection-related hospitalization, studies have not fully elucidated how the risk of CV events changes over time for patients on dialysis. In this work, I will describe the dynamics of CV event risk trajectories for patients on dialysis while conditioning on survival status via multiple time indices: (1) time since the start of dialysis, (2) time since the pivotal initial infection-related hospitalization and (3) the patient's age at the start of dialysis. This is achieved by using a new class of generalized multiple-index varying coefficient models. We report new insights on the dynamics of CV events risk using the United States Renal Data System database, which collects data on nearly all patients with end-stage renal disease in the United States.