added row and column headers but these could be implemented better