mardi 8 septembre 2020

How to use ifelse with dates

I have dates in R in format 01/01/2000

I want to create a column with a category that categorizes my subjects as date of birth before the 01/02/2001 ==1 or after 02/02/2001 ==2. Would this be done with an ifelse?

How would you express this?

Thanks

Aucun commentaire:

Enregistrer un commentaire