can someone help me with the following problem? I have an excel sheet with different date formats in different columns. I would like to upload this excel file as a tibble in R Studion exactly the way it is shown in the excel file. As you can see,however, columns "date2", "date5", "date6", "date7"and "date8" are not uploading the same way as the other columns. How can I modify the code I am using (df <- read_excel('raw_data.xlsx')? The object can stay a Character in the outcome as I can then convert it into a date format.
df <- read_excel('raw_data.xlsx')
Thank you for your help!!
I have already tried to set check.names to FALSE but that wont work either
Excel stores dates internally as "days since origin". You can convert them per the example below:
(It's a good idea to confirm the origin date for the version of Excel you're using, or you may be able to confirm it if you know what one of the dates should be.)
Created on 2024-03-20 with reprex v2.1.0