Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make formulae reach transformations before outer names #109

Merged
merged 1 commit into from
Feb 20, 2024

Conversation

tomicapretto
Copy link
Collaborator

@tomicapretto tomicapretto commented Feb 20, 2024

All the environment machinery built into formulae was working in such a way that names in "outer" environments were reached before the names of "internal" transformations. This caused these kind of problems

p = 1
design_matrices("p(y, n) ~ 1", df)
TypeError: 'int' object is not callable

This PR changes the order in which namespaces are added into the environment so transformations and encodings are reached first.

Copy link

codecov bot commented Feb 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (9bcd01a) 92.62% compared to head (7df836c) 92.63%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #109   +/-   ##
=======================================
  Coverage   92.62%   92.63%           
=======================================
  Files          20       20           
  Lines        2225     2227    +2     
=======================================
+ Hits         2061     2063    +2     
  Misses        164      164           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@tomicapretto tomicapretto merged commit b00f53d into bambinos:master Feb 20, 2024
6 checks passed
@tomicapretto tomicapretto deleted the fix_overlapping_calls branch February 20, 2024 20:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant