Changed variables to vectors