Remove a function from the memory

Remove a function from the memory

Hello
 
It is possible to remove a function from the memory?
 
I have a custom function that I call using modul.StepGuide.init() - but how do I remove that function with all its vars and events, from the memory.
 
Thanks in advance
MG