R for loops run slower when compared to code that handles vectors directly.
This procedure you give can be vectorized as follows:
Get some random values for nw.bank so the calculation can be demonstrated:
nw.bank<- 200*runif(20)-100
[1] 43.273799 19.051499 37.552510 76.940632 -59.176684 -27.379326
[7] -37.512520 77.776610 88.127792 -91.213580 -50.691943 78.697820
[13] 36.933503 -76.973450 28.143336 -55.136574 -70.693362 -14.213375
[19] 15.666707 -3.072321
Note there is only one ampersand (&) in a vectorized AND
as.numeric(((-50<nw.bank) & (50>nw.bank)))
[1] 1 1 1 0 0 1 1 0 0 0 0 0 1 0 1 0 0 1 1 1
Now multiply by 0.001 and take cumulative sum
cumsum(0.001*as.numeric(((-50<nw.bank) & (50>nw.bank))))
[1] 0.001 0.002 0.003 0.003 0.003 0.004 0.005 0.005 0.005 0.005 0.005 0.005
[13] 0.006 0.006 0.007 0.007 0.007 0.008 0.009 0.010
Now you need an adjustable initial value, perhaps, and you are done
rlinit <- 3.0;
rl <- cumsum(0.001*as.numeric(((-50<nw.bank) & (50>nw.bank)))) + rlinit
[1] 3.001 3.002 3.003 3.003 3.003 3.004 3.005 3.005 3.005 3.005 3.005 3.005
[13] 3.006 3.006 3.007 3.007 3.007 3.008 3.009 3.010