Assume that I have the following 100 variables that already have assigned values. This means, I am loading them.
Their assigned names are identical, except for the ending, they end in different numbers:
i.e. D1=23, D2=45,...,D100=67
Is there a quick and efficient way to bind them, preferably as rows. Obviously I could:
D_ALL<-rbind(D1,D2,..,D100)
But is there a quicker way to handle this?
For instance, a loop such as:
for(i in seq(from=1, to=100, by=1))
{
D[i]<-D$i
}
This sort of loop is not going to work in R (it would in STATA with the dollar $
sign).
I am wondering if there is a solution to this. Thanks.