I have a dataframe with dates and values as shown below
df <- read.table(header = T, text = 'ID year date value
1 2019 1/1/2019 1
1 2019 1/2/2019 3
1 2020 1/1/2020 2
1 2020 1/2/2020 4
2 2019 1/1/2019 2
2 2019 1/2/2019 3
2 2020 1/1/2020 4
2 2020 1/2/2020 5')
is there way to convert these values into plots across dates and still put in a dataframe. Is there any package that helps in doing this
expected output. If you can see here plot column has plots across dates for these values
I just got this below stuff in google where I get almost I need.
library(kableExtra)
mpg_list <- split(mtcars$mpg, mtcars$cyl)
disp_list <- split(mtcars$disp, mtcars$cyl)
inline_plot <- data.frame(cyl = c(4, 6, 8),mpg_points2 = "")
inline_plot %>%
kbl(booktabs = TRUE) %>%
kable_paper("hover", full_width = FALSE) %>%
column_spec(2, image = spec_plot(mpg_list, disp_list, type = "p",same_lim = FALSE))

But can we have few features here ?
I need hover tooltip and also if you see the there is no secondary axis between 2 categories. All are in the same line