Back to Community
Japan tearsheet challenge

The third tearsheet challenge is here and this time we're going international -- all the way to Japan! Because of various technical reasons this challenge will be a bit different. The main difference is that global equities are currently only supported in pipeline, not the backtester. As such, you will have to code your factor in pipeline in the notebook. This creates the challenge that for your submission your code would be in the notebook you post. The solution is to delete the code cell with your factor and save the notebook before you submit.

This challenge is a bit more experimental for us. We mainly want to scope out how much alpha we are likely to find in Japan and whether it makes sense for us to start trading there. In addition, we want to motivate you to work with non-US market data. As we currently do not trade the Japanese market, we will not license any factors submitted here in the short-term.

There is also a questionnaire for all entrants that we would appreciate if you filled it out, but you do not have to.

Here are the rules:

  • There is no submission or live-updated leaderboard like for the contest.
  • To enter this challenge, simply post an alpha tearsheet as a reply to this thread. Clone the attached template and add your own pipeline factor code.
  • The deadline to submit a factor is November 15, 2019. There is no hold-out testing, just post your best factor starting on June 1, 2015, until Oct 1, 2018. We will look at all tearsheet submissions and manually determine 5 best factors according to our discretion. Each winner gets a $100 prize. There is no limit on the number of submissions.

Algorithm requirements to enter the challenge:

  • Your factor must be run on the Japanese equities domain. It can however, use any dataset(s) you want.
  • Use the universe provided by the template, or a subset of it.

When selecting a winner, we will primarily look at:

  • Total Sharpe Ratio (IR) over the first 5 days in the alpha decay analysis (higher is better). As the risk model is US-only, there is no specific return or risk exposure analysis.
  • Turnover (lower is better).
  • Universe size (larger is better).
  • For more examples on what we look for, check out our last live tearsheet review.

Good luck and happy coding!

Loading notebook preview...
Notebook previews are currently unavailable.
Disclaimer

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by Quantopian. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. No information contained herein should be regarded as a suggestion to engage in or refrain from any investment-related course of action as none of Quantopian nor any of its affiliates is undertaking to provide investment advice, act as an adviser to any plan or entity subject to the Employee Retirement Income Security Act of 1974, as amended, individual retirement account or individual retirement annuity, or give advice in a fiduciary capacity with respect to the materials presented herein. If you are an individual retirement or other investor, contact your financial advisor or other fiduciary unrelated to Quantopian about whether any given investment idea, strategy, product or service described herein may be appropriate for your circumstances. All investments involve risk, including loss of principal. Quantopian makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances.

57 responses

My first submission - based on factor combination.

Loading notebook preview...
Notebook previews are currently unavailable.

My second submission - Again based on factor combination.

Loading notebook preview...
Notebook previews are currently unavailable.

Revised Model 01

Loading notebook preview...
Notebook previews are currently unavailable.

Model 0.1

Loading notebook preview...
Notebook previews are currently unavailable.

Know it's not what you're looking for turnover wise, but it can't hurt. EDIT: What's with all the cloning? As far as I'm aware no data can be extracted?

Loading notebook preview...
Notebook previews are currently unavailable.

Model 1

Loading notebook preview...
Notebook previews are currently unavailable.

Model 0.1 - Still WIP.

Loading notebook preview...
Notebook previews are currently unavailable.

First attempt at absurdly high turnover (the Notebook ran into memory issues, so I split the simulation, one from 2015-2016 and one 2016-2018).

Loading notebook preview...
Notebook previews are currently unavailable.

Dear Thomas and all,

I noticed that getting results for simulation is not fast and memory expensive here and worked on this problem. Wanted to share my thoughts with community.

There is some 'bad moment' for time and memory during merged_returns DataFrame creation in evaluate_factor() func. It comes from the fact that we simulating returns' pipeline without screen, on all instruments, so we need to 1) filter every of forward returns columns (with factor_result.index) or 2) concat too big pandas dfs (if creating dfs without any factor's index filtering, which is even more costly).
It's done to get forward returns - because if we simply screen on univ_filter, we will get some unexpected NaNs, our filter is changing every day. Here are 2 workarounds:
1. We can "extend" filter for 15 days with simple custom function. I attached some code, there should be one change in evaluate_factor() also. By such screening we reduce returns pipeline size on creation stage.
2. Even more simple and faster - we can store merged_returns DataFrame as global variable.
You can take this code part from evaluate_factor() func and not filter it by factor's index (delete index =... during DataFrame creation). And then use this global variable filtering it by factor's index in evaluate_factor() every time. But this, of course, not improving memory problem.

If I missed something you're welcome.

Loading notebook preview...
Notebook previews are currently unavailable.

Attempt 2

Loading notebook preview...
Notebook previews are currently unavailable.

Model 0.2 - Possibly final.

Loading notebook preview...
Notebook previews are currently unavailable.

First Attempt

Loading notebook preview...
Notebook previews are currently unavailable.

Smoothed. I'll call this my final model 1.0 (for now at least). :)

Loading notebook preview...
Notebook previews are currently unavailable.

Model 02

Loading notebook preview...
Notebook previews are currently unavailable.

My first attempt - Only changing factset.Fundamentals data fields.

Loading notebook preview...
Notebook previews are currently unavailable.

@Oleg - Thank you for the improvement to evaluate_factor! Your solution makes it run faster and use less memory so I updated the notebook in the original post to use your suggested change. Note that I made some small tweaks, changing filter_extend to FilterExtend and changing the window_length to max(returns_lengths)+1, so that it's parametric on the returns_length argument.

Great find!

Disclaimer

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by Quantopian. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. No information contained herein should be regarded as a suggestion to engage in or refrain from any investment-related course of action as none of Quantopian nor any of its affiliates is undertaking to provide investment advice, act as an adviser to any plan or entity subject to the Employee Retirement Income Security Act of 1974, as amended, individual retirement account or individual retirement annuity, or give advice in a fiduciary capacity with respect to the materials presented herein. If you are an individual retirement or other investor, contact your financial advisor or other fiduciary unrelated to Quantopian about whether any given investment idea, strategy, product or service described herein may be appropriate for your circumstances. All investments involve risk, including loss of principal. Quantopian makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances.

Model #1

Loading notebook preview...
Notebook previews are currently unavailable.

initial attempt

Loading notebook preview...
Notebook previews are currently unavailable.

Submisson #1. Fundamentals only. Quantiles show a skew towards naturally favoring long positions.

Definitely a lot of progress to be made!

Loading notebook preview...
Notebook previews are currently unavailable.

Version A.

Loading notebook preview...
Notebook previews are currently unavailable.

Version B.

Loading notebook preview...
Notebook previews are currently unavailable.

How do we get sector and industry classification for global equities?

@Viridian, use the RBICS Focus data.

Edit: Scroll down for v2.1 that replaces this.

Submission #2. Added some estimates factors to my fundamentals (submission #1). Again, quantiles suggest a natural favoring towards long positions.

Loading notebook preview...
Notebook previews are currently unavailable.

Fundy Combo - Sub1

Loading notebook preview...
Notebook previews are currently unavailable.

@Jamie, oh, of course, it's better to make window_length parametric, my bad, thank you.
Glad to help :)

second attempt

Loading notebook preview...
Notebook previews are currently unavailable.

last

Loading notebook preview...
Notebook previews are currently unavailable.

Edit: Submission 2.2 is below. Check that out instead.

Submission #2.1 (replaces my submission 2 above). Added one more factor for smoothing.

Loading notebook preview...
Notebook previews are currently unavailable.

Edit: Scroll down for submission v3.1. It has this factor and two others. Again, my tests show that it is fairly robust over time.

Submission #3. One single factor that my tests showed to be fairly robust over time. Not sure how to best integrate it with other Japan factors, but I thought I'd include it here because of the strong short-term signal I was seeing.

Loading notebook preview...
Notebook previews are currently unavailable.

First submission

Loading notebook preview...
Notebook previews are currently unavailable.

Updated version 1 with larger universe

Loading notebook preview...
Notebook previews are currently unavailable.

RBICS economy neutral algorithm

Loading notebook preview...
Notebook previews are currently unavailable.

A combined factor

Loading notebook preview...
Notebook previews are currently unavailable.

Edit: I have a v2.3 below. Sorry for whoever keeps having to scroll down!

Submission #2.2. Replaces v2 and v2.1.

Loading notebook preview...
Notebook previews are currently unavailable.

Model 03

Loading notebook preview...
Notebook previews are currently unavailable.

Another RBICS economy neutral algorithm

Loading notebook preview...
Notebook previews are currently unavailable.

Three factors

Loading notebook preview...
Notebook previews are currently unavailable.

My second attempt - Using two factset.Fundamentals data fields.

Loading notebook preview...
Notebook previews are currently unavailable.

Model #2

Loading notebook preview...
Notebook previews are currently unavailable.

My first submission

Loading notebook preview...
Notebook previews are currently unavailable.

My 3rd attempt - learning by watching documents.

Loading notebook preview...
Notebook previews are currently unavailable.

Adding in the ML from https://www.quantopian.com/posts/a-machine-learning-template-for-japan-tearsheet-challenge

Loading notebook preview...
Notebook previews are currently unavailable.

v1

Loading notebook preview...
Notebook previews are currently unavailable.

My 4th attempt - Slightly improved

Loading notebook preview...
Notebook previews are currently unavailable.

My second submission

Loading notebook preview...
Notebook previews are currently unavailable.

@Shogo: Those look great, I would investigate what's going on before Oct 2016 where there seems to be a shift in the number of positions as well as the weight distribution (the two lower plots).

Model 04 - Higher Total SR (first 5 - 10.10) with higher turnover rate

Loading notebook preview...
Notebook previews are currently unavailable.

Submission #2.3 (Replaces all previous v2.x). Fundamentals and Estimates.

Loading notebook preview...
Notebook previews are currently unavailable.

Submisson #3.1. Three estimates factors that my tests showed were fairly robust from 2012-present. Here's the tearsheet result for 1/1/12-10/1/18: link

Loading notebook preview...
Notebook previews are currently unavailable.

first submission

Loading notebook preview...
Notebook previews are currently unavailable.

Hi, I know other people have better IR, but I will try anyway.

Loading notebook preview...
Notebook previews are currently unavailable.

Hello, version 2. Slightly improved.

Loading notebook preview...
Notebook previews are currently unavailable.

Model #3

Loading notebook preview...
Notebook previews are currently unavailable.

Model #4

Loading notebook preview...
Notebook previews are currently unavailable.

My 5th attempt - Thank you for an interesting contest!

Loading notebook preview...
Notebook previews are currently unavailable.

Thanks everyone for submitting, looks like some great stuff in here and especially excited to see so many new entrants (arigatou gozaimasu)! We will post the winner announcement details soon. If you're hungry for more, there is a new challenge already posted: https://www.quantopian.com/posts/financials-tearsheet-challenge

Also, if you haven't yet, please fill out the questionnaire we have posted: https://docs.google.com/forms/d/e/1FAIpQLSdZ2-aQkQgO_R6dIygxNcC_Yfs8WFDMjDFtKxtF060U-4RUHg/viewform?usp=sf_link It'll take less than 5 minutes and you can just skip questions you don't want to answer.