lecture 3 - feature engineering Flashcards
types of feature engineering in the time domain
- numerical
- categorical
- mized
we can look at a combination of values in a window and base the prediction on that
numerical time domain
- summarize values of a numerical attribute in a certain window
- mean, max, min, std
small step sizes
- the smaller the window size, the closer you’ll be to the original data
- small window size = more data
categorical time domain
- generate patterns that combine categorical values over time
- pattern types: succession and co-occurrence
- we consider support to identify patterns that occur frequently enough to be considered significant
support Θ
[sum of the number of times the pattern occurs inside window throughout N instances] / [N - λ]
–> by itself and in the historical window
- we extend patterns with sufficient support ( > Θ) to more complex patterns of size k
- k = number of rows considered as a pattern within a window
- k grows over time, the bigger the more complex. bigger k also decreases support.
frequency domain
considers periodic behavior
frequency domain: fourier transformation
- any sequence of measurements can be represented by a combination of sinusoid functions
- find which frequencies are available in the window (frequency decomposition)
fourier transformation steps
- assume a base frequency
- compute a frequency per second for each value of k
- find the amplitudes a(k) associated with the k different frequencies - this way, when we multiply the amplitude with the value for the sinusoid functions, we end up with the original signal again.
- summation formula explains the original signal (x^i_t) as a sum of separate amplitudes
- get feature values (highest amplitude frequency, frequency weighted signal average, power spectrum entropy)
base frequency
- this is the lowest frequency with a complete sinusoid in it
- we can look at k multiples of this base frequency
- k * f_0 represents the k-th multiple of the base frequency
- k is directly related to the number of full sinusoid periods within the given window
- k runs from 0 to λ
frequency per second
- (k * Nsec)/ (λ + 1)
- output in Hz
how many frequencies do we need to cover the entire range of frequencies from the base frequency up to the highest multiple of it?
λ + 1 different frequencies
finding best values for a(k) for a given window of time points
best done with fast fourier transform
definition: highest amplitude frequency
feature that identifies the frequency that has the highest amplitude in the signal
definition: frequency weighted signal
feature that calculates a weighted average of the frequencies, where the weights are the amplitudes of the frequencies
- frequencies with high amplitudes get more weight
definition: power spectrum entropy
- quantifies the amount of signal in the data
- calculates the intensity of each frequency component
- checks whether one or a few discrete frequencies are standing out
- high value = more complex signal