Displaying 1 result from an estimated 1 matches for "oldbal".
Did you mean:
oldval
2013 Jan 18
2
A smart way to use "$" in data frame
...5
The following gives me the balance of state AR:
dataa$newbalance[data$newstate == 'AR']
1170
2700
Now, I have another different data frame datab, it is very similar to data, except that the name of the columns are different, and the order of the columns are different:
oldstate olddate oldbalance oldid oldaccounts
1 AR 31DEC2012 1234 7 40
2 WA 31DEC2012 2222 3 30
3 VA 31DEC2012 2345 5 23
3 AR 31DEC2012 5673 5 23
datab$oldbalance[datab$oldstate== 'AR&...