There is a temptation for accounting PhD students to invest in learning Python. However, I would recommend that accounting PhD students focus more on SAS + Stata than on Python in their first year for a few practical and technical reasons:
- While Python may seem trendy, its user base in accounting research is still relatively small. Research often involves co-authorship. If the research code can only be understood by one person in a research team, it can be counterproductive.
- Due to the limited usage of Python among researchers, Python users cannot take full advantage of the many ready-to-use code written in SAS, which has a larger user base.
- Debugging in Python is more challenging compared to commercial software like SAS and Stata. While freeware may sound appealing, I have always found that I end up spending more time when using freeware, as it typically lacks detailed and excellent help documentation.
- Similar to Stata, Python currently has limitations in manipulating large datasets, as it is constrained by the the computer’s memory size. If you anticipate working with mega datasets such as intra-day bond/stock transaction data, using Python can be a pain.
SAS + Stata is a solid solution that I advocate for. I use SAS for SQL and Stata for all other tasks. Python is well-suited for specific research topics such as textual analysis. If you decide to invest in learning Python, you can rely on the following learning resources:
- The Python Tutorial on the official Python website (https://docs.python.org/3.10/tutorial/index.html) is an easy and quick read.
- There are numerous Python courses available on Udemy (https://www.udemy.com), often offered at discounted prices of $13 per course.
- An excellent methodology article authored by Vic Anand, Khrystyna Bochkay, Roman Chychyla and Andrew Leone (2020), “Using Python for Text Analysis in Accounting Research”, Foundations and Trends® in Accounting: Vol. 14: No. 3–4, pp 128–359. https://dx.doi.org/10.1561/1400000062.
Python also help you choose another career when academia fails you.