Each animal responds to its environment in a dynamic and flexible manner. Behavioral transitions in response to external and internal conditions can be learned or innate actions, mediated by different neuronal circuits throughout the nervous system. I have developed a pipeline to link the neuronal dynamic and synaptic connectivity in the entire central nervous system in small animals. By combining whole brain functional imaging and synaptic connectivity maps, I am able to study complex neuronal circuit mechanisms from multi-sensory inputs to motor outputs. I am using this method to understand how the brain integrates information and makes appropriate behavioral choices, by identifying neurons which predict and evoke behavioral transitions and suppress competing neuronal circuits in the brain of Drosophila melanogaster larva.