Skip to content

RFC: Unified API #109

Description

@wildart

Following #95, I looked at MV models/methods implemented in this package, trying to figure out what would be a type hierarchy and corresponding method interfaces for this package.

Here is a table of models and corresponding function names used by models.

Function \ Model CCA WHT ICA LDA FA PPCA PCA KPCA MDS
fit x x x x x x x x x
transform x x x x x x x x x
predict x
indim x x x x x x x x
outdim x x x x x x x x x
mean x x x x x x x ?
var x x ? ? ?
cov x ?
cor x
projection x x x x x x
reconstruct x x x x
loadings ? ? x x ? ? ?
eigvals ? ? ? ? x
eigvecs ? ? ? ? ?
length
size

I put ? where a possible implementation is missing or called differently.

So, I propose following type hierarchy

  • StatsBase.RegressionModel
    • Methods: CCA, LDA
    • Functions: fit, transfrom, indim, outdim, mean
    • Subtypes:
      • AbstractDimensionalityReduction
      • Functions: projection, var, reconstruct, loadings
      • Subtypes:
        • LinearDimensionalityReduction
          • Methods: ICA, PCA
        • NonlinearDimensionalityReduction
          • Methods: KPCA, MDS
        • LatentVariableModel or LatentVariableDimensionalityReduction
          • Methods: FA, PPCA
          • Functions: cov
  • StatsBase.AbstractDataTransform
    • Whitening
    • Functions: fit, transfrom, indim, outdim, mean, size

@nalimilan @ararslan Thoughts?

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

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions