{
  "name": "Non-Linear Feature Expansion and Transformation Methods in scikit-learn and Scientific Python",
  "description": "Comparative specifications of non-linear basis expansion, spline transformations, and kernel approximation algorithms in scikit-learn and SciPy, detailing mathematical formulation, feature growth rates, support bounds, sparse matrix support, and boundary extrapolation behavior.",
  "page": "https://casrai.org/guides/sklearn-polynomial-features",
  "publisher": "CASRAI",
  "license": "https://creativecommons.org/licenses/by/4.0/",
  "dateModified": "2026-11-14T19:10:16Z",
  "temporalCoverage": "2024/2026",
  "spatialCoverage": "Global",
  "columns": [
    {
      "name": "Method",
      "unit": "",
      "description": "Name of the transformation technique"
    },
    {
      "name": "Scikit-Learn Class",
      "unit": "",
      "description": "Official module and class identifier"
    },
    {
      "name": "Mathematical Basis",
      "unit": "",
      "description": "Form of functional basis expansion"
    },
    {
      "name": "Feature Growth Rate",
      "unit": "",
      "description": "Asymptotic scaling with input dimension n and degree d"
    },
    {
      "name": "Support Type",
      "unit": "",
      "description": "Global vs localized interval support"
    },
    {
      "name": "Sparse Matrix Input",
      "unit": "",
      "description": "Native support for SciPy CSR/CSC matrices"
    },
    {
      "name": "Boundary Hazard",
      "unit": "",
      "description": "Numerical behavior outside training domain bounds"
    }
  ],
  "rows": [
    {
      "Method": "Polynomial Expansion (Full)",
      "Scikit-Learn Class": "sklearn.preprocessing.PolynomialFeatures",
      "Mathematical Basis": "Global monomial powers and cross-products",
      "Feature Growth Rate": "Combinatorial O(n^d)",
      "Support Type": "Global",
      "Sparse Matrix Input": "Yes (Fortran order)",
      "Boundary Hazard": "Runge's phenomenon / rapid boundary divergence"
    },
    {
      "Method": "Polynomial Expansion (Interaction Only)",
      "Scikit-Learn Class": "sklearn.preprocessing.PolynomialFeatures",
      "Mathematical Basis": "Square-free feature cross-products",
      "Feature Growth Rate": "Sum of binomial coefficients",
      "Support Type": "Global",
      "Sparse Matrix Input": "Yes (CSR and CSC)",
      "Boundary Hazard": "Unbounded multiplicative extrapolation"
    },
    {
      "Method": "Piecewise B-Spline Basis",
      "Scikit-Learn Class": "sklearn.preprocessing.SplineTransformer",
      "Mathematical Basis": "Piecewise polynomial B-splines with knots",
      "Feature Growth Rate": "Linear O(n * n_knots)",
      "Support Type": "Local (compact knot intervals)",
      "Sparse Matrix Input": "No",
      "Boundary Hazard": "Controlled (constant extrapolation or periodic)"
    },
    {
      "Method": "Random Fourier Features",
      "Scikit-Learn Class": "sklearn.kernel_approximation.RBFSampler",
      "Mathematical Basis": "Monte Carlo cosine projection of RBF kernel",
      "Feature Growth Rate": "Fixed O(n_components)",
      "Support Type": "Global decaying",
      "Sparse Matrix Input": "No",
      "Boundary Hazard": "Decays toward zero outside sample density"
    },
    {
      "Method": "Nystroem Kernel Approximation",
      "Scikit-Learn Class": "sklearn.kernel_approximation.Nystroem",
      "Mathematical Basis": "Subsampled eigendecomposition of kernel matrix",
      "Feature Growth Rate": "Fixed O(n_components)",
      "Support Type": "Data-dependent landmark support",
      "Sparse Matrix Input": "Yes (kernel dependent)",
      "Boundary Hazard": "Distortions outside sample convex hull"
    }
  ],
  "sources": [
    {
      "title": "scikit-learn PolynomialFeatures Documentation",
      "url": "https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.PolynomialFeatures.html",
      "accessed": "2026-11-14"
    },
    {
      "title": "scikit-learn Generating Polynomial Features User Guide",
      "url": "https://scikit-learn.org/stable/modules/preprocessing.html#generating-polynomial-features",
      "accessed": "2026-11-14"
    },
    {
      "title": "scikit-learn SplineTransformer Documentation",
      "url": "https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.SplineTransformer.html",
      "accessed": "2026-11-14"
    },
    {
      "title": "scikit-learn Kernel Approximation Guide",
      "url": "https://scikit-learn.org/stable/modules/kernel_approximation.html",
      "accessed": "2026-11-14"
    }
  ]
}