Dynamic functional connectivity, i.e., the study of how interactions among brain regions change dynamically over the course of a fMRI experiment, has received wide interest in the neuroimaging literature recently. Current approaches for studying dynamic connectivity often rely on ad-hoc approaches for inference, with the fMRI time courses segmented by a sequence of sliding windows. In this talk, we will discuss Bayesian methods to study dynamic functional connectivity, based on the estimation of time-varying networks. Our approach utilizes a hidden Markov model for classification of latent cognitive states, achieving the estimation of the networks in an integrated framework that borrows strength over the entire time course of the experiment. Furthermore, we assume that the graph structures, which define the connectivity states at each time point, are related within a super-graph, to encourage the selection of the same edges among related graphs. We apply our method to simulated task-based fMRI data, where we show how our approach allows the decoupling of the task-related activations and the functional connectivity states. We discuss the performances of our model on simulations and data from real fMRI experiments.