How do I change the data type of this column

0 votes
Hi, I have two columns in a huge dataset that have "chr" as their data type and I need to change them to "dttm." I used

dataset$colName <- as.datetime( dataset$colName)

That changed the data type but turned every date and time in that column to N/A. How do I change the data type without getting rid of my data? thanks.
Jun 12, 2022 in Data Analytics by Ahmad

edited Mar 4 19 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP