IPython Extension to pretty print nested dicts
Project description
Utilities to work with hierarchical dictionaries
When working with simulation data or simply creating data visualizations, I often find myself wishing for a readable representation of a nested structure. In python these are typically dicts
containing dicts
or something alike.
So, this is where this ipython extension comes in:
- Tab completion across levels for benedicts (plain dicts asap)
- Pretty printing dictionaries and similar types in a tree-like structure.
dict(
lorem = "ipsum",
first_level = dict(
second_level = dict(
some_entry = 8.15,
another_entry = [0, 1, 2, 3, 4],
)
)
)
<class 'dict'>
├── lorem .................................... str ipsum
└── first_level
└── second_level
├── some_entry ..................... float 8.15
└── another_entry ................... list (5)
Install
Optional, but recommended
pip install python-benedict
pip install h5py
Required
pip install ipy_dict_hierarchy
In jupyter or ipython, to load manually
%load_ext ipy_dict_hierarchy
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file ipy_dict_hierarchy-0.0.2.tar.gz
.
File metadata
- Download URL: ipy_dict_hierarchy-0.0.2.tar.gz
- Upload date:
- Size: 7.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bdc36e9b79b98e4fd536a609ac03999e662b316e9bb1a3dc34869e2696c49a7f |
|
MD5 | 172c21ea345df9727d7040f3fc8b4895 |
|
BLAKE2b-256 | edbc31e739ca1483dedec09aeb95f0d44005347f2d1f915268f7c6f872600898 |
File details
Details for the file ipy_dict_hierarchy-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: ipy_dict_hierarchy-0.0.2-py3-none-any.whl
- Upload date:
- Size: 9.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b7262bc76a03513bb7d85348b8b2642dae9479fac294399b9a5707c56380ae1 |
|
MD5 | a9c7c21fc61c203b0b6615c5c9c9e103 |
|
BLAKE2b-256 | 6ff239e74b6d291a17ce8bf1d3409fee5716eb0de9117a970ca14f595c8001e7 |