fix ordering of returns for stacked hists and treatment of kwargs