adding on bar and on_period algorithm examples with new initialisation system: