I want to loop through the rows in a r dataframe (df1) and create columns based on the variable values (v1) on each row.
V1 is a column name on the dataframe df1. What I want to do is add a column using the name V1 onto df2. Variable v1 is of the data type <date> and the values will all be dates.
This is what I tried
for(row in 1:nrow(df1)){
df2 %>%
mutate(row$v1 == "value")
}