Choosing a method#
Start from the scientific input and the output contract, not from a familiar
class name. believe14 keeps methods in three import families while the
registry records supervision, accepted input, approach tags, computational
cost, and whether a cited out-of-sample rule exists.
from believe14 import Capability, list_estimators
all_methods = list_estimators()
assert len(all_methods) == 35
inductive = [
info.name
for info in all_methods
if Capability.TRANSFORM in info.capabilities
]
transductive = [
info.name
for info in all_methods
if info.family != "estimation"
and Capability.TRANSFORM not in info.capabilities
]
print(f"public methods: {len(all_methods)}")
print(f"inductive reducers: {len(inductive)}")
print(f"transductive reducers: {len(transductive)}")
public methods: 35
inductive reducers: 19
transductive reducers: 9
A decision sequence#
Choose the scientific task. Use
estimationfor an intrinsic dimension,linearwhen a global map or interpretable direction is the target, andnonlinearwhen distances, kernels, or local neighborhoods define geometry.Match supervision and input. Labels, continuous targets, and paired views lead to different estimators; precomputed distances and kernels are accepted only where the registry advertises them.
Decide whether new observations must be embedded. A transductive method deliberately has no
transform. FastMap, Kernel PCA, Diffusion Map, Landmark MDS, and Landmark Isomap provide out-of-sample coordinates.Check the failure regime. Read the method card before fitting tied neighbors, a disconnected graph, rank-deficient data, or extreme scales.
Read
diagnostics_. A successful fit reports the solver and honest convergence state; iterative estimators never turnmax_iterexhaustion into convergence.
Registry filters compose, so discovery remains stable as future methods are added.
graph_methods = list_estimators(family="nonlinear", approach="graph")
supervised_linear = list_estimators(family="linear", supervision="supervised")
print("graph:", ", ".join(info.name for info in graph_methods))
print("supervised linear:", ", ".join(info.name for info in supervised_linear))
graph: Isomap, LocallyLinearEmbedding, LaplacianEigenmaps, DiffusionMap, LocalTangentSpaceAlignment, PHATE, LandmarkIsomap
supervised linear: LinearDiscriminantAnalysis, PLSRegression, SlicedInverseRegression, SlicedAverageVarianceEstimation, FisherScore, NeighborhoodComponentsAnalysis
Check neighborhood preservation#
Trustworthiness penalizes neighbors introduced by an embedding. Continuity penalizes original neighbors lost in the embedding. Both scores range from zero to one. Compare them at the same neighborhood size. For exact distance ties, both rankings follow the original row order. The rank penalties follow Venna and Kaski [Venna and Kaski, 2001].
import numpy as np
from believe14.linear import PCA
from believe14.metrics import continuity, trustworthiness
from believe14.neighbors import build_neighbor_graph
from believe14.nonlinear import Isomap
X = np.random.default_rng(14).normal(size=(40, 4))
neighbors = build_neighbor_graph(X, n_neighbors=12)
embeddings = {
"PCA": PCA(2).fit_transform(X),
"Isomap": Isomap(2, n_neighbors=8).fit_transform(X, neighbors=neighbors),
}
for name, coordinates in embeddings.items():
print(name, trustworthiness(X, coordinates, n_neighbors=5),
continuity(X, coordinates, n_neighbors=5))
PCA 0.84296875 0.91625
Isomap 0.85640625 0.9020312500000001
The same graph can serve any smaller neighborhood on the same ordered observations. It stores distances and row indices and excludes each row from its own neighbors. Each estimator applies its own graph weights.
Executable coverage#
This table is generated from the immutable public registry and method-card front matter. The documentation build fails if a card is missing, duplicated, unexpected, or assigned to the wrong family.
Estimator |
Validation status |
Family |
Supervision |
Mode |
Card |
|---|---|---|---|---|---|
PCA |
validated |
linear |
unsupervised |
inductive (linear) |
|
GaussianRandomProjection |
validated |
linear |
unsupervised |
inductive (linear) |
|
FactorAnalysis |
validated |
linear |
unsupervised |
inductive (linear) |
|
ProbabilisticPCA |
validated |
linear |
unsupervised |
inductive (linear) |
|
FastICA |
validated |
linear |
unsupervised |
inductive (linear) |
|
SparsePCA |
validated |
linear |
unsupervised |
inductive (linear) |
|
LinearDiscriminantAnalysis |
validated |
linear |
supervised |
inductive (linear) |
|
CanonicalCorrelationAnalysis |
validated |
linear |
paired |
inductive (linear) |
|
PLSRegression |
validated |
linear |
supervised |
inductive (linear) |
|
SlicedInverseRegression |
validated |
linear |
supervised |
inductive (linear) |
|
SlicedAverageVarianceEstimation |
validated |
linear |
supervised |
inductive (linear) |
|
FisherScore |
validated |
linear |
supervised |
inductive (linear) |
|
LaplacianScore |
validated |
linear |
unsupervised |
inductive (linear) |
|
NeighborhoodComponentsAnalysis |
validated |
linear |
supervised |
inductive (linear) |
|
ClassicalMDS |
validated |
nonlinear |
unsupervised |
transductive |
|
MetricMDS |
validated |
nonlinear |
unsupervised |
transductive |
|
SammonMapping |
validated |
nonlinear |
unsupervised |
transductive |
|
FastMap |
validated |
nonlinear |
unsupervised |
inductive (pivot) |
|
KernelPCA |
validated |
nonlinear |
unsupervised |
inductive (nystrom) |
|
Isomap |
validated |
nonlinear |
unsupervised |
transductive |
|
LocallyLinearEmbedding |
validated |
nonlinear |
unsupervised |
transductive |
|
LaplacianEigenmaps |
validated |
nonlinear |
unsupervised |
transductive |
|
DiffusionMap |
validated |
nonlinear |
unsupervised |
inductive (nystrom) |
|
LocalTangentSpaceAlignment |
validated |
nonlinear |
unsupervised |
transductive |
|
TSNE |
validated |
nonlinear |
unsupervised |
transductive |
|
PHATE |
validated |
nonlinear |
unsupervised |
transductive |
|
LandmarkMDS |
validated |
nonlinear |
unsupervised |
inductive (nystrom) |
|
LandmarkIsomap |
validated |
nonlinear |
unsupervised |
inductive (nystrom) |
|
CorrelationDimension |
validated |
estimation |
unsupervised |
dimension estimate |
|
TwoNN |
validated |
estimation |
unsupervised |
dimension estimate |
|
LevinaBickelMLE |
validated |
estimation |
unsupervised |
dimension estimate |
|
UStatisticDimension |
validated |
estimation |
unsupervised |
dimension estimate |
|
MiNDML |
validated |
estimation |
unsupervised |
dimension estimate |
|
DANCo |
validated |
estimation |
unsupervised |
dimension estimate |
|
TightLocalEstimator |
validated |
estimation |
unsupervised |
dimension estimate |