Skip to content
Prev 169889 / 398506 Next

Problem with retrieving updated variables after attach()

Hello,

suppose I have a data frame:
id age
1 NA  NA
2 NA  NA
3 NA  NA
4 NA  NA
5 NA  NA

Then I attach the data frame:
I assign some new values...
Then I want to create a new data frame from the variables id and age which still are attached to position 2 of the R environment...
ls.pos...2.
1         age
2          id

But this leads to a bogus object... how can I rescue the updated id and age values into new_mat?


Regards,

David