I am currently migrating from R. In R, i used the “do.call” function for many of own functions, which is a generic function that allows to call any arbitrary R function with its arguments in a string. This comes handy if you work with a lot of different distributions in a bigger script - that way I can change sampling procedure relatively easy and fast. Is there something similar in Julia?
func = randn params = "n = 1000, mu = 1, sd = 2" do.call(func, params)
I thought I could instead just create a module where I use the match package (Switch-Case seems to be not supported in Julia?) and manually add the distributions of interest, but the above case seems more convenient to me and I can also use it for other cases. I would assume that the latter case is faster though?
Thank you for your help!