From f1b671fe144a23f07822c20e25b145711fdb86df Mon Sep 17 00:00:00 2001 From: Matthew Wardrop Date: Sun, 28 Aug 2022 22:23:03 -0700 Subject: [PATCH] 0.5.0 --- docsite/docs/changelog.md | 36 ++++++++++++++++++++++++++++++++++++ pyproject.toml | 8 +++++++- 2 files changed, 43 insertions(+), 1 deletion(-) diff --git a/docsite/docs/changelog.md b/docsite/docs/changelog.md index 950491ce..6f165103 100644 --- a/docsite/docs/changelog.md +++ b/docsite/docs/changelog.md @@ -3,6 +3,42 @@ For changes since the latest tagged release, please refer to the --- +## 0.5.0 (28 Aug 2022) + +This is a major new release with some minor API changes, some ergonomic +improvements, and a few bug fixes. + +**Breaking changes:** + +* Accessing named substructures of `Formula` objects (e.g. `formula.lhs`) no + longer returns a list of terms; but rather a `Formula` object, so that the + helper methods can remain accessible. You can access the raw terms by + iterating over the formula (`list(formula)`) or looking up the root node + (`formula.root`). + +**New features and improvements:** + +* The `ModelSpec` object is now the source of truth in all `ModelMatrix` + generations, and can be constructed directly from any supported specification + using `ModelSpec.from_spec(...)`. Supported specifications include formula + strings, parsed formulae, model matrices and prior model specs. +* The `.get_model_matrix()` helper methods across `Formula`, + `FormulaMaterializer`, `ModelSpec` and `model_matrix` objects/helpers + functions are now consistent, and all use `ModelSpec` directly under the hood. +* When accessing substructures of `Formula` objects (e.g. `formula.lhs`), the + term lists will be wrapped as trivial `Formula` instances rather than returned + as raw lists (so that the helper methods like `.get_model_matrix()` can still + be used). +* `FormulaSpec` is now exported from the top-level module. + +**Bugfixes and cleanups:** + +* Fixed `ModelSpec` specifications being overriden by default arguments to + `FormulaMaterializer.get_model_matrix`. +* `Structured._flatten()` now correctly flattens unnamed substructures. + +--- + ## 0.4.0 (10 Aug 2022) This is a major new release with some new features, greatly improved ergonomics diff --git a/pyproject.toml b/pyproject.toml index 7c9ca7b0..4088ce3f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,10 +13,16 @@ readme = "README.md" classifiers = [ "Development Status :: 4 - Beta", "Environment :: Console", + "Topic :: Scientific/Engineering :: Mathematics", "Intended Audience :: Developers", "Intended Audience :: Information Technology", "Intended Audience :: Science/Research", - "Topic :: Scientific/Engineering :: Mathematics", + "Natural Language :: English", + "Operating System :: OS Independent", + "Programming Language :: Python :: 3.7", + "Programming Language :: Python :: 3.8", + "Programming Language :: Python :: 3.9", + "Programming Language :: Python :: 3.10", ] requires-python = ">=3.7.2" dependencies = [