I would like to import a .ics file into R, however, when I try to do so like...
sneak_cal <- read.delim("iCal-TribeEvents.ics", sep = ":", header=FALSE, stringsAsFactors = FALSE, strip.white = TRUE, na.strings = "")
...I end up splitting the character strings of website (belonging to the X-ORIGINAL-URL
or the UID
field) too, which is undesirable
ie https
and //www.kicksonfire.com
The ultimate goal is to get the data into a tidy format where each row represents a single VEVENT
, which I think would be represented by a unique UID
, without any loss of information (such as the URL)
Is there another approach that is recommended, such as pre-defining the fields that are expected as the key and matching the value or empty space to that key? Since the .ics
file has the same expected fields each time, it seems like it might make sense to use those fields as a template to read in the data, but I can not figure out how to do it.