Pandas Create From Multiple Dict
Up to ten columns, one dict per column
- dict1
- dict2
- dict3
- dict4
- dict5
- dict6
- dict7
- dict8
- dict9
- dict10
- DATAFRAME
Pandas Create From Multiple Dict is the pack's answer to "I want to assemble a DataFrame column by column, on the canvas, from separate sources." Instead of one dict that holds every column, you feed it up to ten dictionaries and it merges them into a single DATAFRAME. If you're building a table the way you'd actually work in a node graph - one node per column of data - this is the merge point at the end.
The intended inputs are the pack's Py Kv nodes: Py Kv Float Create, Py Kv Int Create, and Py Kv String Create each set up one column (a name plus a value), and their PYDICT output plugs in here. dict1 and dict2 are required; dict3 through dict10 are optional. The output is a DATAFRAME with a fresh 0-based index.
The rule that bites
All those dictionaries must have equal-length value lists. The node checks python_dict_first_value_len() against every dict you pass and raises a ValueError if the lengths don't match - the queue dies with a Python traceback, not a friendly warning. Column lengths have to agree before you merge; that's standard pandas behavior, just enforced a little less gently here.
Two smaller behaviors worth knowing. If either of the first two dicts is empty, you get back an empty DataFrame (silently, so watch for it). And because the merge is dict.update in order, later dicts win on any key collision - each dict should carry its own unique column name. Keep names distinct and this is painless.
The count matters too: with ten dict inputs this is a chunky node on the canvas. For a hand-typed two-column table, Pandas Create From Dict is simpler. Reach for this one when each column genuinely comes from a different node - real data assembled on the graph, not a table you could type.
Wiring and install
PYDICT sockets render as text widgets; connect into them at the top-left corner of the field - the pack's own user guide warns about this, because the connection point is easy to miss.
The pack isn't in base ComfyUI. Either install via ComfyUI Manager (search "Data analysis") or:
cd ComfyUI/custom_nodes
git clone https://github.com/HowToSD/ComfyUI-Data-Analysis.git
mv ComfyUI-Data-Analysis data-analysis # examples need the lowercase folder
pip install -r requirements.txt
Restart afterward. No GPU, no model files - this whole pack is CPU-only pandas/NumPy/matplotlib wrappers, which is a pleasant change of pace from the rest of your custom_nodes folder.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| dict1 | PYDICT | — | |
| dict2 | PYDICT | — | |
| dict3opt | PYDICT | — | |
| dict4opt | PYDICT | — | |
| dict5opt | PYDICT | — | |
| dict6opt | PYDICT | — | |
| dict7opt | PYDICT | — | |
| dict8opt | PYDICT | — | |
| dict9opt | PYDICT | — | |
| dict10opt | PYDICT | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| DATAFRAME | DATAFRAME | — |