pre_comput_NN: pre_comput_NN: Precompute quantities for SLGP basis...

View source: R/datamanagement.R

pre_comput_NNR Documentation

pre_comput_NN: Precompute quantities for SLGP basis evaluation with nearest-neighbor interpolation

Description

Computes intermediate quantities for evaluating SLGP basis functions using Nearest Neighbor (NN) interpolation over a regular grid in the normalized domain.

Usage

pre_comput_NN(
  normalizedData,
  predictorNames,
  responseName,
  nIntegral = 101,
  nDiscret = 51
)

Arguments

normalizedData

A normalized data frame (values in [0,1]).

predictorNames

Character vector of covariate names.

responseName

Name of the response variable.

nIntegral

Number of grid points for discretizing the response domain.

nDiscret

Number of grid points for discretizing the covariate domain.

Value

A list of intermediate quantities used in SLGP evaluation:

  • nodes: grid of response × covariates,

  • indNodesToIntegral: response bin indices,

  • indSamplesToNodes: sample-to-node index mapping,

  • weightSamplesToNodes: equal weights for NN interpolation.


SLGP documentation built on Sept. 9, 2025, 5:25 p.m.