My Python imports for exploratory data analysis
With Python Jupyter and SciPy stack, we can quickly set up a very interactive environment for exploratory data analysis (EDA).
Here I listed the libraries I normally used. I just import all of them in the first cell in a Jupyter notebook, and then start working on the data. When the analysis is almost done, then I will start cleaning up and removing the redundant ones. I find easier to remove lines than to think of the exact name of a library/module to import.
The list could be long, and for clarity, I usually loosely categorize them into a few groups groups separated by empty newline such as:
- Python standard libraries
- Scipy Stack libraries
- Other third-party libraries
- My own written modules
The imports are loosely ordered by usage frequency or name length.
At the end of imports, there are also commonly used setup for libraries such as matplotlib and pandas, and IPython magic commands.