udpated to return float if float input in spline evaluation (rather than return an array of size 1)