Skip to content

Data

relationalai.semantics.frontend.base
Data(
df: DataFrame,
model: Model,
schema: dict[str, Concept] | None = None,
register_columns: bool = True,
)

Represents a temporary table backed by in-memory data.

Data objects are created by Model.data (and the convenience function data). They behave like a Table, so you can refer to their columns (for example d.name or d["name"]) in queries.

Most users should not instantiate this class directly. Prefer Model.data.

DataTableConceptVariableDSLBase
 semantics
├──  frontend > base
│   └──  Model
│       └──  data
└──  data
RelationalAI Documentation
├──  Build With RelationalAI
│   └──  Understand how PyRel works > Build a semantic model
│       └──  Declare data sources
│           ├──  Use a DataFrame with Model.data
│           └──  Use inline Python data with Model.data
└──  Release Notes
    └──  Python API Release Notes
        └──  What’s New in Version 1.0.5
            └──  New Features and Enhancements