Stockertim Dictionary · Technology · Artificial intelligence
Feature engineering
Also called feature construction, feature creation
In short
Turning raw data into useful model inputs, for example converting a price series into returns, volatility or ratios, and aligning each value with the time it became known.
- Advanced
- Process
- Checked
In detail
Raw data rarely arrives in a form a model can use well. Feature engineering is the work of transforming it: cleaning errors, filling or flagging gaps, combining fields, scaling numbers to comparable ranges and creating new measures that capture what matters. A closing price on its own says little; the percentage change over a month, its volatility or its distance from a moving average can say much more.
In financial data the steps often include converting prices to returns, building ratios from accounting figures, lagging values so that each reflects only what was published by a given date, adjusting for share splits and dividends, and encoding categories such as sector or country. For text, it may mean turning news into sentiment scores or counts of key words. Domain knowledge guides which transformations are likely to carry real signal.
Engineering carries risks. Computing an average over the whole data set and then using it in training lets information from the future seep in. Trying hundreds of transformations and keeping those that test well invites overfitting. Good practice fits every transformation only on training data, records exact definitions and timestamps, and tests the finished model on genuinely unseen periods.
Worked example
A share closes at 100 on day 1 and 105 on day 2, and its company reports annual earnings of 10 per share on day 2.
- Daily return feature: (105 / 100) − 1 = 5%
- Price-to-earnings feature on day 2: 105 / 10 = 10.5
- Timing: the earnings figure is usable from day 2 onward, not for any earlier day.
Two engineered features are created, each stamped with the date it became available.
In practice
Quantitative investment teams, credit risk modellers and fraud analysts spend much of their time on feature engineering. Automated machine-learning tools can generate features, but reviewers still check them for timing, meaning and fairness.
Watch out
- Scaling or filling gaps using statistics from the whole data set leaks test information into training.
- More features are not automatically better; each one adds a chance of spurious patterns.
Learn it properly
Official sources
- 6.4 Introduction to time series analysis (NIST/SEMATECH e-Handbook of Statistical Methods) · National Institute of Standards and Technology
- Artificial Intelligence Risk Management Framework (AI RMF 1.0) · National Institute of Standards and Technology
Facts last checked on 4 November 2026.
Education, not advice: the Stockertim Dictionary explains what terms mean. It never recommends buying or selling anything.