Book Image

Python for Finance

By : Yuxing Yan
Book Image

Python for Finance

By: Yuxing Yan

Overview of this book

Table of Contents (20 chapters)
Python for Finance
About the Author
About the Reviewers

Chapter 5. Introduction to Modules

In this chapter, we will discuss modules, which are packages written by experts or any individual to serve special purposes. In this book, we will use about a dozen modules in total. Thus, knowledge related to modules is vitally important in our understanding of Python and its application to finance.

In particular, we will cover the following topics:

  • What is a module and how do we import a module?

  • Showing all functions contained in an imported module

  • Adopting a short name for an imported module

  • Comparing between import math and from math import *

  • Deleting an imported module

  • Importing a few functions from a module

  • Finding out all built-in modules and all available (reinstalled) modules

  • How to find a specific uninstalled module

  • Finding the location of an imported module

  • Module dependency

  • One super package including many modules

  • Online searching of modules and videos on how to install a module