I have a variable which consists of numerical values which is between -1 and 1. I want to create a new variable where the value is the mid range between specific intervals.

So far, I have done
forvalues I = -0.5(0.1)0.5 {
display `i'
}
what to do next?

Thank you in advance.