change the global variable to a new sample component