documentation for writing tables