How it works...

First, we need to transform the single feature into a vector representation, as the .StandardScaler(...) method accepts only vectorized features. 

Next, we instantiate the .StandardScaler(...) object. The withMean parameter instructs the method to center the data with the mean, while the withStd parameter scales to a standard deviation equal to 1.

Here's what the standardized representation of our signal look like. Note the different scales for the two lines:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset