Skip to Content
Python算法交易
book

Python算法交易

by Yves Hilpisch
November 2022
Intermediate to advanced
392 pages
10h 8m
Chinese
China Electric Power Press Ltd.
Content preview from Python算法交易
130
|
第
4
章
图 4-17: GLD ETF 的总表现和均值回归策略(SMA = 43,阈值 = 7.5,交易成本为 0.1%)
4.5
数据窥探和过度拟合
本章以及本书的其余部分,重点是使用
Python
对重要概念进行技术实现。有时会随
意选择使用的策略,参数,数据集和算法,有时会特意选择以说明某个问题。毫无
疑问,在讨论应用于金融的技术方法时,看到示例显示“结果良好”会更加令人振
奋和鼓舞,即使这些示例可能不会在例如其他金融工具或时间段上一概而论。
展示具有良好结果的示例的能力通常是以数据窥探为代价的。根据
White
(
2000
)
的说法,可以将数据窥探定义如下:
当出于推理或模型选择的目的而多次使用给定的数据集时,就是数据窥探。
换句话说,可以对同一数据集几次或非常多次地应用某种方法,以获得令人满意的
数字和曲线图。当然,这在交易策略研究中在思想上是不真实的,因为它假定交易
策略具有一定的经济潜力,这在真实世界中可能是不现实的。因为本书的重点是使
用
Python
作为算法交易的编程语言,所以数据窥探方法可能是合理的。这类似于一
本数学书,该数学书举例说明了一个方程式,该方程式具有可以轻松识别的独特解
掌握向量化回测
|
131
决方案。在数学中,这样简单明了的例子不是规则而是例外,但是它们经常用于教
学目的。 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

人工智能技术与大数据

人工智能技术与大数据

Posts & Telecom Press, Anand Deshpande, Manish Kumar
图解大模型 : 生成式AI 原理与实战

图解大模型 : 生成式AI 原理与实战

Jay Alammar, Maarten Grootendorst

Publisher Resources

ISBN: 9787519869694