Use Generic vectors in KernelDensity and Transform