Skip to main content

No project description provided

Project description

Tangly is a module that allows you to visualize tables in python

Instal with

pip install tangly

And to import:

import tangly

Say you have a nested list with information about people, like so:

people = [["Name", "Last Name", 'Age', "Number"],
	   ["Nath", "Dezem", '20', '137'],
	   ["Rafa", "Rayes",'19', '4976'],
       ['Johny', 'Dias', '22', '1234']]

To display this as a table we use the 'print_table()' command:

print_table(people)

Output:

┌───────┬──────────────────────────┐
│ Name  │ Last Name   Age   Number │
├───────┼──────────────────────────┤
│ Nath  │ Dezem       20    137    │
│ Rafa  │ Rayes       19    4976   │
│ Johny │ Dias        22    1234   │
└───────┴──────────────────────────┘

You can controll which collumns and rows are separated using a similar nested list, like so [[0,2],[0,1]]. By default this is [[0],[0]] which means only the first row and first collumn are separated.

print_table(my_list, [[0,2],[0,1]] )

Output:

┌───────┬───────────┬──────────────┐
│ Name  │ Last Name │ Age   Number │
├───────┼───────────┼──────────────┤
│ Nath  │ Dezem     │ 20    137    │
│ Rafa  │ Rayes     │ 19    4976   │
├───────┼───────────┼──────────────┤
│ Johny │ Dias      │ 22    1234   │
└───────┴───────────┴──────────────┘

I did this in 2019 when I was learning python. I know no one will ever use this.

Current version = 3.0.2

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

tangly-3.0.2-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file tangly-3.0.2-py3-none-any.whl.

File metadata

  • Download URL: tangly-3.0.2-py3-none-any.whl
  • Upload date:
  • Size: 2.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.6

File hashes

Hashes for tangly-3.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 72f2ef562262d3ba5d27f3d53db156a44cafece52b118a0d7730f10cc338be60
MD5 21a19db6783f93b49f4310feb23e3401
BLAKE2b-256 9945b5be41f1c4c989c075facc66160baaf305dee0f1aca9d0a1c4da44b3de60

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page