Automatic Function loading

I have created a function that calculates the time to either numbers or percentages of an insect emergence that fits a Gompertz model almost exactly.

What I am curious about is that I find I am using this function quite often and was wondering if there is a way to call the function from code without having to make sure that I have previously run it. I know I can cut and paste but if I can have Julia just load and run the function when it encounters it that would make it easier for this absent minded programmer that tends to do stupid stuff like this.

Define it in your .julia/config/startup.jl file.

(more normally one would create a package with such a function, and load the package whenever one wants to use it).

1 Like

I initially thought of a package but the code is only 5 lines long and seemed like a bit of overkill.