강의

멘토링

로드맵

Inflearn brand logo image
BEST
Career

/

Finance

Data-driven stock quant investment with Python Part 2

This lecture is a follow-up lecture to 'Python Data-Based Stock Quant Investment Part 1'. If Part 1 was more of an introduction, Part 2 is an in-depth lecture that focuses on the entire flow of practical strategy implementation and quantitative investment development. This class focuses on advanced Pandas techniques for handling time series data, and how to implement signal-based strategies and static/dynamic asset allocation strategies that require adjusting asset weights at various intervals based on this. Furthermore, it goes beyond strategy implementation and learns about 'code framework' that directly verifies and backtests various investment strategies with minimal code modifications, how to extend this to improve it so that it can lead to actual investment, and what to watch out for in this process. In addition to the programming component, you can experience the best Python quant investment flow that you cannot find in investment books, blogs, YouTube, etc. by deeply covering theoretical contents such as the two types of return concepts (simple return, log return) and evaluation indicators related to backtesting.

(4.8) 44 reviews

1,062 learners

  • DeepingSauce
Pandas
Investment
Quant

Reviews from Early Learners

What you will learn!

  • What you need to know to properly preprocess time series data with Pandas

  • Deep understanding and codification of various terms (log return, etc.) and performance indicators (Sharpe, MDD, etc.) used in the quantitative world.

  • Various price-based indicators used in investment (moving average, etc.) and implementation of strategies utilizing them

  • How to implement a signal (buy, sell signal)-based strategy 'consistently' and its principles

  • How to implement asset allocation & rebalancing-based strategies 'consistently' and its principles

  • Implementation and comparison of results of various asset allocation strategies used in practice

Invest in stocks strategically and smartly!
Take on the challenge of data-driven investing with Python!

Full curriculum roadmap
Get 30% off all Roadmap lectures (click)

Individual course discount event (up to 30%)
Go to the event (click)

🙌 Who is this lecture for?

  • Part 1: For whom is this lecture intended? Please refer to the lecture details page.
    • This course is especially good for students who want more advanced, practical content than the Part 1 class.

The fundamental reason why I started giving lectures,
This is exactly what I wanted to convey to my students!


🙌 What will I be able to do after taking the course?

1. Implement backtesting and compare performance for various strategies.

(The above graph was created using a library called plotly instead of matplotlib for better readability)

2. You can solve the following questions (questions) ' by yourself (directly)' + 'easily '.

  1. Backtesting & Data Analysis
    • (N:M ratio for two specific stocks) vs (all-in on one stock) which is better?
    • Correlation between All-Weather and VAA Strategy Portfolio Returns
  2. Rebalancing period
    • (Rebalancing at the end of the month) vs (Rebalancing at the beginning of the month)
    • Stocks:Bonds:Gold = 6:3:1 strategy --> One month, six months, or one year rebalancing?
    • I can't tell if the backtest in the paper waited until the end of the month and the beginning of the month and then switched to defensive assets at the time of rebalancing, or if it switched to defensive assets immediately when the canary asset sign changed 😭😭
  3. Tweaking the strategy
    • What happens if you ride the wave of an all-weather strategy?
    • Which of the following is better for stock assets in All Weather?
      1. Developed country stocks (VT)
      2. US stocks (VTI) / developed market stocks (VEA) / emerging market stocks (VWO)
    • I want to include a certain percentage of virtual currency in my static asset allocation. Is that okay?
    • Would it be okay to have a 50/50 ratio of stocks for a specific strategy?
    • What are the returns and MDD data when purchasing only when the canary asset group is + during the DAA strategy?

The previous lectures were merely a preparatory course to properly take this lecture.
The core and final content of the 'Python + Stock Quantitative Investment' curriculum!


🙌 Knowledge Sharer's Practical Portfolio

  • Practical portfolio management based on the content covered in this lecture
  • Strategic Composition: 4 Korean, 5 US, 2 Cryptocurrencies
  • Assets under management: N200 million
  • reference
    • As seed investment (including currency exchange) for the overall strategy began to stabilize and programmatic tracking of each account and asset in the portfolio began in early 2021, the 'Benchmark Comparison Graph' only provides 2021 results.
      • Dividends are not reflected.
      • Certain strategies may have some errors as they do not accurately track the portfolio composition or asset status prior to past rebalancing.
      • In the event of a large market drop, assets that were additionally purchased to realize short-term profits were not reflected.
    • Before 2021, the starting point was not consistent because the investment timing for each strategy was not the same.
    • Rebalancing cycles vary by strategy (monthly, quarterly, semi-annually, annually, etc.).
    • Some brokerages only provide the last 6 months of returns and only provide that graph.

Programming is not something to be studied and practiced.
It is a tool for efficiently solving real-world problems.


📣 Pre-Course Checklist: Is this course worth taking?

  1. [Python Basics] Satisfies one of the two conditions below.
    • Completed Python course, accessible to anyone, from liberal arts students to non-majors.
    • Or you know 'all' about the content below.
      • Any for statement can be converted to a while statement.
      • I am familiar with the concepts of libraries and modules.
      • I am well aware of the difference between classes and objects.
      • You can distinguish between situations where you should use the list data type and when you should use the dictionary data type.
      • Have experience using jupyter lab or notebook.
  2. [Pandas Proficiency with Financial Data] Meets one of the following two conditions:
    • Completed Part 1 of Data-Driven Quantitative Stock Investing with Python
    • Or you know 'all' about the content below.
      • I know the difference and relationship between DataFrame and Series.
      • When performing arithmetic operations (add, divide, etc.) between DataFrames or Series, I understand the index and column alignment.
      • I have experience performing simple data preprocessing on my own using Pandas. (e.g., I improved code using a for loop by converting it to Pandas.)
      • I know the difference between concat(), join(), and merge().
  3. [Basic Math Knowledge] I have **simple** experience learning the following (not required)
    • Basic probability/statistics, including the meaning of random variables, expected value (E[X]), and variance (Var[X]).
    • The meaning of independence in probability/statistics
    • The meaning and relationship between log and exponential, and the characteristics of log (how to add logs with the same base)

If you've checked all of the above checklists, you're a good candidate for this course :)


📣 Things to note before taking the class

  • This is not a course on implementing an automated trading system (securities firm API + GUI program for buying/selling).
  • The data provided in this lecture is sample data intended to demonstrate the application of what you've learned. Therefore, it may not be immediately applicable to real-world situations.
  • Responsibility for your investments always lies with the investor.

📖 Check out related lectures

Recommended for
these people

Who is this course right for?

  • If you felt the joy of learning while taking the course 'Python Data-based Stock Quant Investment Part 1' and want to feel that joy once more,

  • Those who want to create new strategies by back-testing and applying strategies they have encountered in books, lectures, etc., rather than simply accepting them.

  • Anyone who wants to experience a backtesting architecture that frames strategies by feature and allows implementation of various strategies with minimal code modifications

  • Anyone who would like to hear about the things to keep in mind when converting backtesting code to code for actual use

  • Anyone who wants to gain a deep understanding of terms/knowledge required for quantitative investment such as log rate of return, Sharpe Ratio, and annualized return, and how to use them correctly

  • Anyone who wants to experience one quantitative investment flow from financial time series data preprocessing to backtesting

  • Those who want a class where students can apply the learning content on their own by understanding the principles, rather than a class where they simply run the code given by the instructor

Need to know before starting?

  • Contents of 'Python that anyone can learn, whether they are a liberal arts student or a non-major'

  • Contents of 'Data-based stock quant investment with Python Part 1' (or an equivalent understanding of the Pandas library)

  • The class 'Python Web Crawling & Automation to Replace My Work' is not directly related to this class, but if you take it, the utilization of the contents of this lecture will greatly increase (because you can freely obtain the desired stock-related data).

  • Middle/high school level math and probability/statistics (see OT video for details)

  • See roadmap: https://www.inflearn.com/roadmaps/474

Hello
This is

16,202

Learners

580

Reviews

326

Answers

4.8

Rating

5

Courses

데이터로 미래를 설계하고 현실의 문제를 해결하는 데이터 엔지니어입니다.

데이터 기반 통찰을 사랑하며, 평생 학습(Life-long Learner)하고 지식을 나누는 기여자(Contributor)가 되고자 합니다

Curriculum

All

65 lectures ∙ (16hr 26min)

Course Materials:

Lecture resources
Published: 
Last updated: 

Reviews

All

44 reviews

4.8

44 reviews

  • jaeyoul jon님의 프로필 이미지
    jaeyoul jon

    Reviews 2

    Average Rating 5.0

    5

    97% enrolled

    파이썬 초급 강의 빼고 전부 수강했습니다. 제가 들었던 강의들중 가장 쉽고 통찰력있게 잘 가르쳐 주십니다. 닥분에 많이 배워 갑니다. 감사합니다!

    • DeepingSauce
      Instructor

      안녕하세요! 첫 수강평 감사드립니다 :) 부족한 강의 계속 관심 가져와주셔서 감사드리고, 재열님 원하시는 목표에 꼭 도움이 되는 강의가 되었으면 좋겠네요!

  • learn_learn님의 프로필 이미지
    learn_learn

    Reviews 5

    Average Rating 5.0

    5

    6% enrolled

    선생님! 원래 파이썬 기초 수업만 들으려고 했던 수업인데, 강의 내용뿐만아니라 커리큘럼이 너무 좋아서 마지막 강의까지 물흐르듯이 오게되었습니다. part1 수업 듣고 제 전략을 만들면서 코드적으로 막히는 부분이 꽤 있었는데, part2를 보면서 더 많은 부분을 개선시킬 수 있을 것 같습니다(아직 100% 이해는 못해서 한번 더 수강할 예정입니다). 혹시 part3는 예정에 없으신 걸까요? 계속 강의 내주셨으면 좋겠습니다. 무조건 수강하겠습니다.

    • 법경님의 프로필 이미지
      법경

      Reviews 49

      Average Rating 4.9

      5

      98% enrolled

      여기저기 찾던 강의 예요!

      • psy67039772님의 프로필 이미지
        psy67039772

        Reviews 1

        Average Rating 5.0

        5

        100% enrolled

        • Andy_Choi LGIT QA1님의 프로필 이미지
          Andy_Choi LGIT QA1

          Reviews 2

          Average Rating 5.0

          5

          31% enrolled

          감사합니다

          Limited time deal ends in 7 days

          $79,200.00

          20%

          $77.00

          DeepingSauce's other courses

          Check out other courses by the instructor!

          Similar courses

          Explore other courses in the same field!