Is there a Package to assess “redundancy” (for want of a better word) in R functions across packages (i.e. to find out how many functions do the same job across a sample of R packages)? If not, what would be a good starting point for a function to do this (or is it even reasonably possible)?
You can programatically get function bodies and parameters and compare the code within functions themselves, so you could find some duplicates that way. I’d imagine you could have some functions though with different code in them that both give the same result; i guess in that case you’d have to run the functions with the same input and compare outputs.
1 Like