I have two data frames df1 and df2 , now I am comparing two dataframes , dataframes are so big can't share reproducible example but getting error while executing.
objective is to list out the variables or records which are different from another data frame. I am trying like below but getting error .
both the data frame were just read and then compare
New <- as.data.frame(df1)
old <- as.data.frame(df2)
compare_DF <- dataCompareR::rCompare(df1,df2)
Error in value[3L] :
ERROR:Error in as.data.frame.default(doa): cannot coerce class ‘"function"’ to a data.frame
First compare their columns are same by the great function in janitor package. janitor::compare_df_cols(df1,df2)
If the columns are identical make sure they are in the same order and then convert the data.frames to data.table (I always work in data.tables as they are much faster than classical R data.frames)