Skip to content

refactoring: code review linear models #1016

Open

Description

@josef-pkt

A few items while reading linear_model.py

There are several errors and many warnings reported by pylint. (no bugs AFAICS)
Some code would benefit from a refactoring.

we can open specific issues for the details

  • RegressionModel has no whiten method (pylint): should it raise NotImplementedError, methods that need to be defined by subclasses
  • sandwich:
    • they define het_scale as public attribute: no explanation, temp variable?, private?
      update: They are described in the class docstring for HCx_se, and are the adjusted squared residuals.
    • should they use only whitened attributes ?
    • make the robust covariances into lazy cache_readonly properties
  • norm_resid is unused and untested (according to comment)
  • silencing other pylint messages, e.g. weights not defined because indirectly attached
  • scale : Is argument in RegressionResults.__init__ (ignored), and as cached attribute
  • more ?

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions