All notable changes will be documented here.
structlog
to 23.2.0
- Bug fixes and performance improvements that should have gone in here
STRINGIFY_INDEX_VALUES
isFalse
by default (index.name
will still be a string, but values will keep their original type)- Added comms listener for renaming (SQL cell) dataframes.
2022-08-21
pd.Series
as a default renderable type (to go with the existingpd.DataFrame
andnp.ndarray
types)- Support for the following data types inside
pd.DataFrame
columns:type
andnp.dtype
shapely.geometry
objectspd.Timedelta
anddatetime.timedelta
pd.Period
pd.Interval
complex
numbersipaddress.IPv4Address
and.IPv6Address
- Extra dataset generation functions for development/testing under
dx.utils.datatypes
dx.quick_random_dataframe(n_rows, n_columns)
to get apd.DataFrame
of 0.0-1.0 floats (convenience wrapper forpd.DataFrame(np.random.rand(n_rows, n_columns))
)dx.random_dataframe()
with different boolean values to enable based on available datatypes (dx.DX_DATATYPES
)
settings_context
context manager to allow temporarily changing a setting (or multiple)- Logging via
structlog
(default level:logging.WARNING
)
- Default sampling method changed from
outer
torandom
- Displaying a dataframe with an out-of-order index (like with
.sample()
) no longer resets the index before sending data to the frontend. - Index/column flattening and string-formatting is behind settings and is handled more explicitly
dx
should no longer interfere with other media type / mime bundles (e.g. matplotlib) formatted by the existing IPython display formatter
2022-08-05
- Helper text for adjusting settings after a dataset has been truncated
.reset_index()
when a custom/MultiIndex is used to preserve0-n
row numbers at theindex
level- Support for geopandas GeoDataFrames and GeoSeries objects
dx.random_dataframe(num_rows, num_columns)
convenience function- More tests!
default
display mode (vanilla pandas) renamed toplain
- Properly pass
metadata
through during theIPython.display
calls to render dataresource/dx formatted data plain
display format tests use a basic IPythonDisplayFormatter
instead ofNone
2022-07-22
- Additional metadata sent to frontends to triage issues with output sizes and
dx
settings
simple
/enhanced
display modes no longer raise JSON errors trying to serializepd.NA
valuesSAMPLE_METHOD
returning incorrect value (True
instead ofDXSampleMethod
) when compared withCOLUMN_SAMPLE_METHOD
andROW_SAMPLE_METHOD
- Truncating rows no longer alters dtypes by adding
...
values
2022-07-22
- Direct support for
application/vnd.dataresource+json
media type display formatting - reverting all settings to
pandas
defaults withdx.reset()
or switching to theDISPAY_MODE
setting todefault
pydantic
dependency for BaseSettings usepandas
-inspireddx.set_option(setting_name, setting_value)
dx.set_display_mode()
convenience function for globally switching betweensimple
(simpleTable/DEX),enhanced
(GRID), anddefault
(vanilla pandas)
- Auto-truncating rows and columns of
pd.DataFrame
objects based onDISPLAY_MAX_ROWS
,DISPLAY_MAX_COLUMNS
, andMAX_RENDER_SIZE_BYTES
(1MB default) size limits before rendering (forsimple
&enhanced
display modes), with blueprintjs flavored warningsSAMPLING_MODE
setting to better control how truncating happens ("first", "last", "outer", "inner", and "random" options)RANDOM_SEED
setting for random sampling
- Support for non-string column and index values (possibly temporary) to allow
build_table_schema
to work withpd.MultiIndex
values
2022-05-06
- Lowered the minimum required
ipython
version from8.2.0
to7.31.1
2022-04-26
dx.register()
(dx.enable()
, deprecated) anddx.deregister()
(dx.disable()
, deprecated) will now update the default display formatting for pandasDataFrame
objects as intended
2022-04-25
- Updated minimum
python
version to3.8
(down from3.9.6
in 1.0.0)
- Custom
IPython
formatter for Noteable environments - Additional data type support for
display()
/dx()
:- any tabular structure (lists of dicts, dict of
{column: [values]}
, etc) that can be loaded into a pandasDataFrame
.csv
and.json
file paths
- any tabular structure (lists of dicts, dict of