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

lin reg: add exclude to predict #354

Merged
merged 4 commits into from
Dec 19, 2023

Conversation

mathause
Copy link
Member

@mathause mathause commented Dec 19, 2023

I need to think a bit more about this - I wrote this so we can split up the linear regression. However, this will include the intercept twice. So I may have to add the possibility to add the intercept in exclude.

if "intercept" in exclude:
    prediction = xr.zeros_like(params.intercept)
else:
    prediction = params.intercept

Copy link

codecov bot commented Dec 19, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (67a7194) 87.88% compared to head (f31247f) 87.89%.

❗ Current head f31247f differs from pull request most recent head a1ccf7b. Consider uploading reports for the commit a1ccf7b to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #354   +/-   ##
=======================================
  Coverage   87.88%   87.89%           
=======================================
  Files          40       40           
  Lines        1742     1743    +1     
=======================================
+ Hits         1531     1532    +1     
  Misses        211      211           
Flag Coverage Δ
unittests 87.89% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@mathause mathause marked this pull request as ready for review December 19, 2023 17:25
@mathause mathause merged commit 80856c7 into MESMER-group:main Dec 19, 2023
5 checks passed
@mathause mathause deleted the lr_predict_exclude branch December 19, 2023 18:05
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.

allow skipping predictors in LinearRegression.predict
1 participant