Is it possible to print an editable html table into officedown powerpoint?

247 Views Asked by At

I am trying to automate a PowerPoint presentation deck using officer in R. I am mostly working with the gt() package to make some tables (as I like the versatility of it) but the issue is that officedown requires me to save the gt() stuff as .png before I can paste it into powerpoint. This is all good and well but I would like to be able to modify the said table.

One of the great things about the gt() package is that I can save the table as a raw html format. However, I have no idea how to print the said html thing in the following code for my presentation.

my_pres <- pres %>%
 remove_slide(index = 1) %>% 
 add_slide(layout = "Title Slide", master = "Useless") %>%
 ph_with(value = "Gaetano was here" , location = ph_location_label(ph_label = "Title and Company Name")) %>%
 add_slide(layout = "Definitions", master = "Useless") %>%
 #ph_with(value = "Methodology & Definitions", location = ph_location_label(ph_label = "Methodology")) %>%
 ph_with(value = Definitions, location = ph_location_label(ph_label = "Definitions"),
         level_list = c(1L, 2L, 2L, 2L, 3L, 4L, 5L, 2L)) %>%
 add_slide(layout = "Graphs", master = "Useless") %>%
 ph_with(value = extimg3 , location = ph_location_label(ph_label = "Graphs"))  # extimg3 is where I want my table to appear. 

I am not working in markdown as I do not believe that markdown works with officer.

0

There are 0 best solutions below