Beatson, Alexander, 1759-1830, army officer and colonial administrator