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

Add support for categorical y in MarginalEffects #24

Open
andywong36 opened this issue Jan 23, 2023 · 1 comment
Open

Add support for categorical y in MarginalEffects #24

andywong36 opened this issue Jan 23, 2023 · 1 comment
Labels
question Further information is requested

Comments

@andywong36
Copy link
Contributor

Arises from the following snippet:

        if y is not None:
            X['_actual'] = y
            agg_kwargs['actual'] = ('_actual', y_aggfun)
            agg_kwargs['actual_lower'] = ('_actual', lambda s: s.quantile(.25, interpolation='lower'))
            agg_kwargs['actual_upper'] = ('_actual', lambda s: s.quantile(.75, interpolation='higher'))

.quantile is not a valid function on categorical y

@andywong36
Copy link
Contributor Author

This precipitates more questions.

  1. What would the marginal_effects plot look like for binary outputs?
  2. Does it even make sense to have marginal_effects support multi-class outputs?

@jwdink jwdink added the question Further information is requested label Jan 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants