Displaying 1 result from an estimated 1 matches for "exceptin".
Did you mean:
exception
2010 Nov 15
2
Extracting from data.frame
Can someone please explain the following behavior?
df1 and df2 are data.frames. Suppose I want a subset of the rows
(observations) using extraction, say just the first row. What I want to know
is why if df1 has just one column then df1[1,] returns a vector, whereas if
df2 has 2 or more columns then df2[1,] returns a data frame? Why is the
single column case different?
[[alternative HTML