I get the following error: Error in [<-.data.frame ( *tmp* , match(Subset_df$cell_name, Empty_df$cell_name), : missing values are not allowed in subscripted assignments of data frames
I have seen other forum questions in which they use !is.na or subset(), but as I'm not an expert in R, I don't know to place this in the code and get it to run.
The replacement methods can be used to add whole column(s) by specifying non-existent column(s), in which case the column(s) are added at the right-hand edge of the data frame and numerical indices must be contiguous to existing indices. On the other hand, rows can be added at any row after the current last row, and the columns will be in-filled with missing values. Missing values in the indices are not allowed for replacement.
This likely means there's a missing value in your Freq column of Full_df.
Here's a reprex for this error.
x <- data.frame(a=c(NA,2:5), b=c(1:5))
x[x$a==2,]$b
#> [1] NA 2
x[x$a==2,]$b <- 99
Error in `[<-.data.frame`(`*tmp*`, x$a == 2, , value = list(a = c(NA, :
missing values are not allowed in subscripted assignments of data frames
I think a good path forward is to start your goal for this operation, what are you trying to do? With a reprex, folk here could probably suggest an alternative.