Skip to content

Let DummyCoding() specify a subset (or superset!) of levels #308

Description

@droodman

Stata lets you economically state models with a subset of possible dummies for a given categorical variable:

regress y i(1 3).x

That regresses y on two dummies, one for x==1, one for x==3.
It would be nice for the levels option of DummyCoding() to allow the same.

One can also do

regress y ibn.x, nocons

Which specifies a complete dummy set and no constant term. ("bn" means "base, none") DummyCoding() could accept base=:none to do the same.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions