printtools/table.py
def table(t, vline=True, render=False, **kwargs):
    """Print or render an ASCII table."""
    # Ensure table has same dimensions
    for row in t:
        assert len(row) == len(t[0])

    t = [[str(cell) for cell in row] for row in t]
    tout = (__table_standard if vline else __table_nosep)(t, **kwargs)

    if render:
        return tout
    else:
        print(tout)
Print or render an ASCII table.
Print or render an ASCII table.
Print or render an ASCII table .
def table(t, vline=True, render=False, **kwargs):
    for row in t:
        assert len(row) == len(t[0])
    t = [[str(cell) for cell in row] for row in t]
    tout = (__table_standard if vline else __table_nosep)(t, **kwargs)
    if render:
        return tout
    else:
        print(tout)
def table ( t , vline = True , render = False , ** kwargs ) : for row in t : assert len ( row ) == len ( t [ 0 ] ) t = [ [ str ( cell ) for cell in row ] for row in t ] tout = ( __table_standard if vline else __table_nosep ) ( t , ** kwargs ) if render : return tout else : print ( tout )
Print or render an ASCII table.
Print or render an ASCII table .
"""Print or render an ASCII table.""" # Ensure table has same dimensions
t
vline
render