Skip to content

helper function pattern extra methods that may return pandas with index #2145

Open

Description

@josef-pkt

looking at possible solution for prediction standard errors #719

What data/interface handling do we need for an extended predict function?
(besides the actual calculation code)

  • converting exog is in base.model.Results.predict going through patsy if necessary
  • row index if exog is DataFrame/Series - this seems to be missing in current predict

to the latter:

OLSResults.outlier_test returns DataFrame with row_labels if available
We might have it also in other methods or auxiliary functions and classes but I don't have an overview.

We may need helper functions or private methods that are able to wrap arrays similar to wrappers but outside of predefined model Results.


for predict we have two cases, exog used in estimation and exog given as argument.
in outliers_influence we only calculate at the exog used in estimation.

Activity

  1. josef-pkt commented on Dec 20, 2014

    @josef-pkt
    MemberAuthor

    actually the wrapper design for auxiliary results is not obvious.

    We cannot wrap individual results arrays as pandas Series if it's also used internally by other methods, without making a detour. (This is what I thought we could switch to.)
    We can stick to the pattern of having a summary_frame method, but then individual results will not be lazily or on demand available as pandas series. We need extra options in summary_frame for users to choose what should be calculated and included.

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