I have a huge data frame from which I only select a couple of rows. Then I remove some of the columns based on a condition. let us say that I choose row 4460 as shown bellow:
V1870 V107 V1315 V1867 V1544 V1207 V1252 V1765 V342 V429 V1826 V865 V1374
4460 0 0 3 0 5 0 2 0 4 0 0 0 0
The problem is that I need to convert this row to a simple vector ( meaning I should get rid of all the column/row names) so that I can pass it to another function. I would like to be able to have the following result:
[1] 0 0 3 0 5 0 2 0 4 0 0 0 0
I tried as.list
and as.vector
, but none of them gave the results I was expecting. Any idea?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…