To be precise, in the case I am looking this time f is not a function, but f <- ggplot2::ggproto(...)
So debug(f) produces Error in debug(f) : argument must be a function Iago ________________________________ De: R-help <r-help-boun...@r-project.org> de part de Iago Gin� V�zquez <iago.g...@sjd.es> Enviat el: divendres, 12 d�abril de 2024 14:15 Per a: r-help@r-project.org <r-help@r-project.org> Tema: [R] Debugging functions defined (locally) inside another functions Hi all, I am trying to debug an error of a function g defined and used inside another function f of a package. So I have f <- function(whatever){ ... g <- function(whatever2){ ... } ... } If I wanted to debug some thing directly inside f I would do debug(f). But this does not go inside g code. On the other hand, debug(g) does not work as g is not a defined function in the namespace of the package. Is there some way to debug errors inside g? Thank you in advance. All the best, Iago [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.