The Return On Equity (ROE) field is calculated from
Net Income / Average Total Common Equity
The income and equity values are based upon quarterly reports and are trailing twelve month (TTM) values. Net income is the bottom-line profit, before common-stock dividends are paid, reported on a firm’s income statement. Common equity is assets minus liabilities reported on a firm's balance sheet. It is the accounting value that's left for shareholders in the event a company settled its liabilities with its reported assets. Both of these values are obtained from quarterly reports.
Because ROE is calculated from quarterly report data it generally will only change quarterly. This is why ROE today is almost always the same as ROE N days ago. It will generally only change when a new, or updated, quarterly report is issued.
The Price Earnings ratio (PE) field is calculated from
Adjusted Close Price / Earnings per Share (EPS)
The EPS value is based upon quarterly reports and are trailing twelve month (TTM) values. It will generally only change quarterly. However, the close price will change daily. Therefore, one typically sees the PE value change daily. This is why PE today is almost never the same as PE N days ago.
Your 'Roe_yesterday' custom factor is working properly and isn't a bug. Hope that makes sense.
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.