Exploration and Exploitation of Action Selection in the Motor Cortex and Basal Ganglia.