rtimeline

Generating timeline with R package timelineS


My R script looks like this

if (!require("timelineS")) install.packages("timelineS")
library('timelineS')

myevents <- read.csv(
text = "MS1.1.1,2021-12-01
MS1.1.2,2022-03-01
MS1.1.3,2022-09-01
MS1.1.4,2022-09-01
MS1.1.5,2022-09-01
MS1.1.6,2022-11-01
MS1.1.7,2023-03-01
MS1.1.8,2023-09-01
MS1.1.9,2023-09-01",
sep=",",header=F)
head(myevents)
class(myevents)
timelineS(myevents)

and I get the error "Fehler in min(event.dates) - buffer.days : nicht-numerisches Argument für binären Operator". I cannot figure out where is my mistake.

Thank you for any hint!


Solution

  • ?timelineS
    myevents$V2 <- as.Date(myevents$V2)
    timelineS(myevents)