Skip to content

Ordinal regression #533

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

Merged
merged 17 commits into from
Jun 2, 2023
Merged

Conversation

NathanielF
Copy link
Contributor

Example Notebook using Ordinal Regression Model

Related to this issue: #277

Notebook is a work in progress. Just experimenting with different model specifications on fake data with known properties.
Current plan is fit and explain the regression model with a discussion of the priors over the cut points and evaluating different implications of the model specification. Rough plan is to then apply the techniques to examples in Agresti's book on categorical data analysis.

Helpful links

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@NathanielF
Copy link
Contributor Author

Marking this one as ready for a pull request because I think i have the bones of what I want... but not quite the structure. I also know @drbenvincent has thoughts on this one too. So opening it up for feeback or pushback, suggestions

Broad structure at the moment is

  1. Open with scenario of employee rating system to motivate the view of a latent sentiment and explicit rating.
  2. Generate fake data and visualise it. Explain the nature of the regression model
  3. Run a variety of models
  4. Plot outcomes
  5. Use Krushcke's movie data set to compound the importance of modelling ordinal data properly
  6. Conclude

@NathanielF NathanielF marked this pull request as ready for review March 22, 2023 21:12
@drbenvincent
Copy link
Contributor

Great stuff. Reviewing this and the other notebook is definitely on my list 🙂

@drbenvincent
Copy link
Contributor

I hope to have time to review this Friday or Monday. Feel free to ping me if I violate that 🫠

@NathanielF
Copy link
Contributor Author

Giving this one a nudge @drbenvincent

@drbenvincent
Copy link
Contributor

Thanks for the reminder. A bunch of house move things get finished today, so should have capacity for this very soon :)

@NathanielF
Copy link
Contributor Author

Just giving another nudge here @drbenvincent. At this point i'm pretty happy with it.

@drbenvincent
Copy link
Contributor

Sorry, taking a look now :)

@drbenvincent drbenvincent self-requested a review June 1, 2023 15:08
Copy link
Contributor

@drbenvincent drbenvincent left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • In the intro, add wikipedia link to Likert scale page
  • Could potentially add seed for RNG in the make_data function. But entirely optional
  • Can we easily remove the Unnamed: 0 column in df?
  • Where it says "brainchild of Dr Ben Vincent", add Adrian Seyboldt also. I can't quite remember how it came about, but it was some mix of both of us.
  • Could add some alpha to the histogram plots
  • Change "Normal V Uniform Priors" title to say "versus"
  • Comparison to statsmodels is nice, but could have a short description to focus the reader to any salient points.
  • Plot under heading "Interrogating the Model's Implications" is cool but could perhaps have a brief explanation.
  • Update dates to June 2023 (sorry)

Very nice 👍

@NathanielF
Copy link
Contributor Author

Made those changes. Think we're all good now. Thanks for the review!

@drbenvincent drbenvincent merged commit ab389da into pymc-devs:main Jun 2, 2023
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.

3 participants