I want to convert text strings to numerical values using Javascript in order to create custom variables for a survey link. For example, I have the following possible values for the variable Q14:
Inland Great Lakes Rivers Coastal N/A
How can I convert these text values into numerical valuesso that Inland=1, Great Lakes=2, Rivers=3, Coastal=4, N/A=5?