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算法交易
Python
和算法交易
|
17
实现类和模块,这些类和模块将让任何算法交易项目更加高效。不过,整个过程中
使用的主要软件包是
NumPy
和
pandas
。
图 1-1:从 2013 年初到 2020 年中的美元计价的历史比特币汇率
NumPy
提供了基本的数据结构来存储数值数据并使用它,而
pandas
则
带来了强大的时间序列管理功能。同时
pandas
很好地将其他程序包的
功能包装成了易于使用的
API
。从刚刚描述的比特币示例可以看到,
对
DataFrame
对象的单个方法调用已经足以生成两种金融时间序列数据
的可视化图形。像
NumPy
一样,由于在后台大量使用了编译后的代码,
pandas
可以让即使是相当简洁的矢量化代码也能运行得非常快。
1.2
算法交易
算法交易这个术语没有一个唯一的或是普遍的定义。基本上来说,它指的是基于某
种形式算法进行金融工具交易。算法是按一定顺序为了实现特定目标而进行的一组
操作(数学和技术上的)。例如,存在一些数学算法可以解决魔方的问题。
注
4
这种
注 4: 参见 The Mathematics of the Rubik
’
s Cube (
https://oreil.ly/16pIA
)或 Algorithms for
Solving Rubik
’
s Cube(
https://oreil.ly/XM0ZP
)。
18
|
第
1
章
算法通常可以完美地通过一步一步地过程来解决手头的问题。另一个例子是如果一
个方程存在根的话,找到这个根的算法。从这个意义上讲,数学算法的目标通常是
明确规定的,并且通常期望得到一个最优解。 ...
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