Kernel Density.Fit Transformed Method
Fits a boundary-corrected density in log or logit coordinates.
Definition
Namespace: Numerics.NET.Statistics
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.9.0
C#
An immutable transformed fit. Queries and densities use original coordinates; bandwidth metadata is exposed directly in transformed coordinates.
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.9.0
public static KernelDensityEstimate FitTransformed(
Vector<double> input,
KernelDensityTransformation transformation,
KernelDensityOptions? options = null,
Vector<double>? weights = null
)Parameters
- input Vector<Double>
- Nonempty finite observations, strictly inside the transformation bounds, including any zero-weight entries. Observations are snapshotted.
- transformation KernelDensityTransformation
- The monotone transformation and declared support bounds.
- options KernelDensityOptions (Optional)
- Kernel and bandwidth options in transformed coordinates, or null for Gaussian normal reference.
- weights Vector<Double> (Optional)
- Optional finite nonnegative relative observation masses, paired by position, matching the input length and containing positive mass. Null gives equal mass.
Return Value
KernelDensityEstimateAn immutable transformed fit. Queries and densities use original coordinates; bandwidth metadata is exposed directly in transformed coordinates.
Remarks
The change-of-variable Jacobian is included in density and log-density. Fixed widths,
adjustment and bandwidth-selection criteria apply to transformed observations. Endpoint observations
are rejected; no arbitrary epsilon offset is applied. Existing unbounded fitting is unchanged.
Exceptions
| Argument | The input or transformation is null. |
| Argument | An observation or weight is invalid, automatic selection has insufficient transformed spread, or the selected width is not representable. |