The optional init() function of a tiddlywiki macro is automatically invoked by the TW core during the startup process, but after all the plugins have been loaded.
config.macros.MacroName={
init: function() {
...
// your init code
...
},
handler: function(place, macroName, params, wikifier, paramString, tiddler){
}
}