function FindNearest(const Data: TVec; ASample: Double): Integer;
Return the index of the nearest value.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Data | TVec | |
| 2 | ASample | Double | scalar |
Returns: Int32
Remarks:
Return the index of the value within data where the expression abs(Data[Index]- ASample) is smallest.