[R] level sets of factors are different
Richard van Wingerden
ros110 at gmail.com
Sat Jan 7 12:11:59 CET 2006
Hi,
I have two data frames A en B.
I want to filter B with values of A
data_frame_b
names <- colnames(data_frame_b[1:1, ])
filtera <- data.frame(data_frame_a[1:1])
print(nrow(filtera))
if (nrow(filtera)>0){
filtered_frame_b <- subset(data_frame_b, ColumnX == filtera[1, 1], names)
}
The results are:
[1] 124
Error in Ops.factor(ColumnX, filtera[1, 1]) :
level sets of factors are different
What is wrong??
Richard
More information about the R-help
mailing list