can not find function "export" in shiny server

I am trying to plot a 2D figure and then export it as a png graphy in a web application using shiny. The coding snapping is as following.

p <- plot_ly(data = pca.df, x =pca.df[,paste0('Axis',sel.xaxis)], y = pca.df[,paste0('Axis',sel.yaxis)], mode = "markers",color = ~popnames,marker=~list(size=8,color=color),text=~paste0('Ind. name= ',ind.names,"\n ,Pop:", popnames))
export(p,file = "pca_2_1.png")

The coding works fine if I run it locally in Rstudio,
but when I try to run it via a URL link (this link connect to a linux server, where shiny server installed), I get the error that the function export can not find. How could I install the package in shiny server? Which package does function"export" belong to in r?
Is there any one could help?
Thank you.
Best regards

4.7.900 (plotly version) and above includes the orca() function (replacing the export() function), which exports images locally, but requires the processx package. See plotly documentation

1 Like