Home > Mobile >  How to edit package functions in R?
How to edit package functions in R?

Time:01-25

I would like to make subtle changes to a visualisation from the UpSetR package. Within the upset() function there is another sub-function called Make_size_plot() that creates the bar chart which I would like to change.

library(UpSetR)

I figured using the trace() function would be one way to do it.

trace(upset, edit=T)

However, I only managed to edit the upset() function but not the Make_size_plot() function on line 162 within the upset() function.

How can I edit the Make_size_plot() function the easiest way, e.g. without creating my own package or forking the Github repo?

CodePudding user response:

have you tried

trace(UpSetR:::Make_size_plot, edit=T)
  • Related