initial code for hstack