Shopify-inspired forecasting pipeline combines numerical features collected from merchants with different units and scales. You need to standardize a feature using its mean and standard deviation so the training pipeline receives a consistent representation.
Standardise one feature: subtract its mean and divide by its population standard deviation. A constant feature is mapped to zeros.
Implement solve(x).
Returns. Return a float NumPy vector with mean 0 and standard deviation 1 (or all zeros for a constant input).
Example 1
Input:
solve([1, 2, 3])
Output:
[-1.224745, 0.0, 1.224745]
Example 2
Input:
solve([4.0, 4.0, 4.0])
Output:
[0.0, 0.0, 0.0]
No results yet
Run your code to check it against the examples, or submit to run every test.