Reference
The redivis
python modules provides an interface to construct representations of Redivis entities and to create, modify, read, and delete them.
Resources are generally constructed by chaining together multiple constructor methods, reflecting the hierarchical nature of entities in Redivis. For example, to list all variables on table (which belongs to a dataset in an organization), we would write:
Interfaces
The redivis namespace. Provides constructor methods for most of the other classes.
Class representing a Redivis dataset. Provides constructor methods for Tables and Queries scoped to a given dataset, as well as methods for creating, deleting, and updating datasets.
Class representing a non-tabular file on Redivis.
Class representing a Redivis organization. Provides constructor methods for Datasets and Workflows scoped to a given organization.
Class representing a Redivis workflow. Provides constructor methods for Tables and Queries scoped to a given workflow.
Class representing a running SQL query that references tables on Redivis.
Class representing a tabular data upload on a Table.
Class representing a Redivis table. Numerous methods available for reading data from the table, as well as uploading data and metadata.
Class representing a Redivis user. Provides constructor methods for Datasets and Workflows scoped to a given user.
Class representing a specific variable with a Table.
Environment variables
REDIVIS_API_TOKEN
Important: this token acts as a password, and should never be inlined in your code, committed to source control, or otherwise published.
REDIVIS_DEFAULT_WORKFLOW
If set, tables referenced via redivis.table()
and unqualified table names in redivis.query()
will be assumed to be within the default workflow. In Redivis notebooks, this environment variable is always set to the current workflow.
REDIVIS_DEFAULT_DATASET
If set, tables referenced via redivis.table()
and unqualified table names in redivis.query()
will be assumed to be within the default dataset.
REDIVIS_TMPDIR
Pandas datatype conversions
When loading a Redivis table into pandas using these dtypes, the following conversions will apply:
Float
float64
DateTime
pd.Timestamp
(np.datetime64[ns]
)
Date
pd.Timestamp
(np.datetime64[ns]
)
Time
object
(with datetime.time
objects)
Geography
If a pandas.DataFrame: str
If a geopandas.GeoDataFrame: geopandas.GeoSeries
dtype="numpy"
Boolean
bool
Boolean
with nulls
object
(with values True
, False
, None
)
Integer
int64
Integer
with nulls
float64
String
str
dtype="numpy_nullable"
Boolean
pd.BooleanDtype()
Integer
pd.Int64Dtype()
String
pd.StringDtype()
Last updated
Was this helpful?