I have a dataframe:
x<-c(10,80,30,40,50,10,20,80,90,100)
y<-c(15,10,35,45,90,65,75,85,80,90)
E<-seq(1,10,by=1)
data <- data.frame(x,y,E)
From this data
i want to extract a sub - dataframe data1
, that is included in data
:
x1<-c(10,80)
y1<-c(15,85)
E1<-c(1,8)
data1<-data.frame(x1,y1,E1)
names(data1)<-c("x","y","E")
and I want to get the residual data frame (data
- data1
).
I prefer something that use x
and y
values to get the residual df, and if it's possible, a generally use code, without blocking the position of the data rows.