I tried Google this, but it's hard to explain what I am trying to do.
I am returned with a string var returnedString = model one. 
Suppose I have a bunch of arrays called
var model_one   = ['a', 'b', 'c']
var model_two   = ['d', 'e', 'f']
var model_three = ['f', 'g', 'h']
This is what I have done
var selectedArrayName = returnedString.replace(" ", "_") //model_one
And this is what I want to do...
for (i in array with name selectedArrayName) {
    print selectedArrayName's array index. 
}  
 
     
     
    