How to create a Wave variable before append?
Before we need to append two waves/ trackers datasets, we should have a common variable in both the datasets to differentiate the respondents between those two datasets. To create a Wave/ Flag variable, use the below syntaxes in R to create the same.
# Old Tracker
tracker <- loadDataset("<provide URL of the dataset>")
# New Tracker data
ds <- loadDataset(<provide URL of the dataset>)
# Let's make a variable to flag the old and new cases
tracker$Wave <- VarDef(data=factor("Wave 1"), name="Wave", type="categorical")
ds$Wave <- VarDef(data=factor("Wave 2"), name="Wave", type="categorical")