formulaic icon indicating copy to clipboard operation
formulaic copied to clipboard

Draft: Add support for the patsy `Q` transform.

Open matthewwardrop opened this issue 2 years ago • 0 comments

Motivated by #115 , this is a quick draft demonstrating a Q transform that replicates the behavior of the patsy Q function.

Notes:

  • This syntax is not as nice as ...., but may be valuable when users are migrating over to formulaic from patsy.
  • Perhaps this should be gated by a patsy compatibility flag.
  • Perhaps _data and _context should be passed in separately, to avoid name collisions / weird data types.
  • Perhaps it isn't worth adding at all? And just have people migrate over to ... syntax, or furnish formulaic with their own Q implementation (only merge the context bits).

matthewwardrop avatar Oct 09 '22 22:10 matthewwardrop