Nodes/ComfyUI-Data-Analysis/CDA String Create
ComfyUI Node

CDA String Create

Turn a text field into a proper string node

By HowToSD·Created 2 years ago·Updated about a year ago· 23
CDA String Create
    • STRING
    data

    CDA String Create looks like the most pointless node in the pack - a single-line text field that outputs exactly what you typed. But "text in a widget" and "a string on a wire" are different things in ComfyUI, and this node is the conversion. If a node in the Data-Analysis pack asks for a string input - a column name, a title, a label - and you want to supply it from a dedicated, visible node instead of typing into a cramped widget, this is the tool.

    It's part of the CDA (ComfyUI Data Analysis) IO family in HowToSD's ComfyUI-Data-Analysis pack. The author's description is "Creates a Python String using a value entered in a single-line text field." Note the "single-line" - if you need multiline, its sibling CDA Text Create is the one. They're identical under the hood; the only difference is the widget.

    How it works

    The implementation is a straight pass-through: return (data,). What you type is what you get. No parsing, no conversion, no validation. Its value is purely structural - it takes a widget and turns it into a first-class node on the canvas, with a wireable STRING output you can route to multiple consumers.

    Inputs and outputs

    • data (required, STRING, single-line) - the text.
    • STRING output - the same text, as a wireable output.

    When you'd actually use it

    Two situations make it worth adding to a graph:

    • Reusability. A column name like "hits" or a chart title you'll reference in several nodes: define it once in CDA String Create, wire it everywhere. Change one node, and every consumer updates.
    • Cleanliness. In the pack's plotting nodes (MPL Bar, MPL Line, MPL Scatter), the x_column_name and y_column_name fields are plain string widgets. If you're building a template workflow, having those names as visible, labeled nodes beats hunting widgets.

    It's also the natural string half of the create/show pattern: CDA String Create → some node → CDA Show Float/Int to verify the outcome, or into Pandas Show Text to render a string on screen.

    Installing it

    Ships with the pack - install once for the whole family. ComfyUI Manager: search "Data analysis", install ComfyUI-Data-Analysis, restart, reload. Manual:

    cd ComfyUI/custom_nodes
    git clone https://github.com/HowToSD/ComfyUI-Data-Analysis
    mv ComfyUI-Data-Analysis data-analysis   # README: examples depend on this folder name
    pip install -r data-analysis/requirements.txt
    

    Dependencies: pandas, matplotlib, seaborn, scipy, scikit-learn, openpyxl, lxml. No GPU, no model downloads. The PyTorch nodes moved to the separate ComfyUI-Pt-Wrapper extension in March 2025.

    Gotchas

    • Single line only. Paste a newline and behavior gets weird; use CDA Text Create for anything multi-line.
    • No escaping. What you see is what's passed - if you need quotes embedded in the string, include them literally.
    • It's a pass-through. It won't validate that a string is a real column name. Wire into Pandas Columns / a show node to confirm the value matches before you feed it to a plotting node that will error on a bad name.
    CategoryData Analysis

    Inputs (1)

    NameTypeDefaultDescription
    dataSTRING

    Outputs (1)

    NameTypeDescription
    STRINGSTRING