- Python Machine Learning By Example
- Yuxi (Hayden) Liu
- 165字
- 2021-07-02 12:41:35
Polynomial features
If we have two features, a and b, we can suspect that there's a polynomial relation, such as a2 + ab + b2. We can consider each term in the sum to be a feature—in this example, we have three features. The product ab in the middle is called an interaction. An interaction doesn't have to be a product—although this is the most common choice—it can also be a sum, a difference, or a ratio. If we're using a ratio to avoid dividing by zero, we should add a small constant to the divisor and dividend.
The number of features and the order of the polynomial for a polynomial relation aren't limited. However, if we follow Occam's razor, we should avoid higher-order polynomials and interactions of many features. In practice, complex polynomial relations tend to be more difficult to compute and tend to overfit, but if you really need better results, they may be worth considering.
- 現(xiàn)代測(cè)控電子技術(shù)
- 網(wǎng)絡(luò)服務(wù)器架設(shè)(Windows Server+Linux Server)
- Python Artificial Intelligence Projects for Beginners
- Photoshop CS4經(jīng)典380例
- Java開發(fā)技術(shù)全程指南
- Visual C# 2008開發(fā)技術(shù)實(shí)例詳解
- 大數(shù)據(jù)挑戰(zhàn)與NoSQL數(shù)據(jù)庫技術(shù)
- 計(jì)算機(jī)網(wǎng)絡(luò)技術(shù)基礎(chǔ)
- 基于企業(yè)網(wǎng)站的顧客感知服務(wù)質(zhì)量評(píng)價(jià)理論模型與實(shí)證研究
- Visual FoxPro程序設(shè)計(jì)
- SQL Server數(shù)據(jù)庫應(yīng)用基礎(chǔ)(第2版)
- 3ds Max造型表現(xiàn)藝術(shù)
- Photoshop CS4數(shù)碼照片處理入門、進(jìn)階與提高
- Natural Language Processing and Computational Linguistics
- 空間機(jī)器人智能感知技術(shù)