to print horizontal graph