Ghost Light is my favourite Doctor Who story and absolutely everything in it makes sense. Give it another watch, there's a lot to soak up but the explanations are all there.
Basically, Light was head of a ship that surveyed all life in the universe in order to catalogue it. A Survey agent working for Light (Originally one of the lizard things!) decided he wanted to be the daddy in charge and sealed Light in the ship. Survey then decided to evolve to the top of Earth's evolutionary progress, a Victorian gentleman. Thus Survey assumes the identity of Josiah. Survey then captures and brainwashes the explorer Fenn-Cooper in to a planned assassination plot against Queen Victoria, so Survey can take over the British Empire.
However, things go wrong and Light escapes his imprisonment. He goes slightly batshit insane when he realises life can never be catalogued and plots to fuck the world up. However, The Doctor manages to convince him that stopping evolution is impossible and thus causes Light to overload. His presence remains in the house though, and is what a young Ace is frightened of in the future.