Financials - Quick OverviewThis unique indicator is designed to provide traders and investors with a concise yet comprehensive view of a company's financial health and sector classification. It features an intuitive table displayed prominently on the chart, offering a blend of essential company information and key financial metrics. This tool is ideal for those looking to integrate fundamental analysis into their technical trading strategy.
Key Features:
Company Sector Information: Get a quick glimpse of the company's industry sector, aiding in understanding its market position and comparative performance within its industry.
Financial Overview: The table includes vital financial data such as Earnings and Sales, providing insights into the company's revenue and profitability.
Growth Metrics: Track both quarter-over-quarter (QoQ) and year-over-year (YoY) growth, offering a dynamic view of the company's performance over time.
Operating Margin Percentage (OPM%): Understand the efficiency of the company's operations with the OPM%, which indicates the proportion of revenue that remains after paying for variable costs of production.
Price-to-Earnings (PE) Ratio: Assess the company's stock value relative to its earnings, an essential metric for valuation and comparative analysis within the sector.
Usage: This indicator is particularly useful for investors and traders who incorporate fundamental analysis into their decision-making process. By providing key financial data directly on the chart, it allows for a more integrated approach to technical and fundamental analysis. The indicator is designed to be straightforward and easy to interpret, making it suitable for both seasoned investors and those new to financial analysis.
P-value
Free cash flow yieldThis script shows
- FCF Yield Net based on enterprise value. See reference: www.investopedia.com
- FCF Yield Diluted: which reduced CFC net by dilution amount.
- FCF % change.
This should give you a good overview on how well the company is at growing FCF and how efficiently they are creating FCF.
TASC 2023.12 Growth and Value Switching System█ OVERVIEW
This script implements a rotation system for trading value and growth ETFs, as developed by Markos Katsanos and detailed in the article titled 'Growth Or Value?' in TASC's December 2023 edition of Traders' Tips . The purpose of this script is to demonstrate how short-term momentum can be employed to track market trends and provide clarity on when to switch between value and growth.
█ CONCEPTS
The central concept of the presented rotation strategy is based on the observation that the stock market undergoes cycles favoring either growth or value stocks. Consequently, the script introduces a momentum trading system that is designed to switch between value and growth equities based on prevailing market conditions. Specifically tailored for long-term index investors, the system focuses on trading Vanguard's value and growth ETFs ( VTV and VUG ) on a weekly timeframe.
To identify the ETF likely to outperform, the script uses a custom relative strength indicator applied to both VTV and VUG in comparison with an index ( SPY ). To minimize risk and drawdowns during bear markets, when both value and growth experience downtrends, the script employs the author's custom volume flow indicator (VFI) and blocks trades when its reading indicates money outflow . Positions are closed if the relative strength of the current open trade ETF falls below that of the other ETF for two consecutive weeks and is also below its moving average. Additionally, the script implements a stop-loss when the ETF is trading below its 40-week moving average, but only during bear markets.
The script plots the relative strengths of the value and growth equities along with the signals triggered by the aforementioned rules. Information about the current readings of the relative strength and volume flow indicators, along with the current open position, is displayed in a table.
█ CALCULATIONS
The script uses the request.security() function to gather price data for both equities and the reference index. Custom relative strength and volume flow indicators are calculated based on the formulas presented in the original article. By default, the script employs the same parameters for these indicators as proposed in the original article for VTV and VUG on a weekly timeframe.
CAPM Model with Returns TableThe given Pine Script is designed to implement the Capital Asset Pricing Model (CAPM) to calculate the expected return for a specified asset over various user-defined periods and compare it with the asset's historical mean return. The core features and functionalities of the script include:
Inputs:
Benchmark Symbol: Defaulted to "CRYPTOCAP:TOTAL". This serves as a comparison metric.
Risk-free Rate: Represents the return on an investment that is considered risk-free.
Benchmark Period: Used for plotting purposes. It doesn't affect table calculations.
Period Settings: Allows users to specify four different time periods for calculations.
Functionalities:
Computes daily returns for the benchmark and asset.
Calculates beta, which represents the volatility of the asset as compared to the volatility of the benchmark.
Uses CAPM to estimate expected returns over user-defined periods.
Generates a table displaying the expected return and asset's mean return for each period.
Provides implications based on the comparison between the expected returns and the asset's historical returns. This is showcased through a mutable label that is updated with each bar.
Visualization:
Plots expected return and asset's mean return over the benchmark period.
Provides a horizontal line to represent zero return.
Use Case:
This script can be helpful for traders or analysts looking to gauge the potential return of an asset compared to its historical performance using the CAPM. The implications provided by the script can serve as useful insights for making investment decisions. It's especially beneficial for those trading or analyzing assets in the cryptocurrency market, given the default benchmark setting.
Note: Before relying on this script for trading decisions, ensure a thorough understanding of its methodology and validate its assumptions against your research.
BETA Benchmark - Tables!The indicator measures and plots the average beta of the defined periods of the selected asset, benchmarked with TOTAL.
Stablecoin Supply Ratio Oscillator
The Stablecoin Supply Ratio Oscillator (SSRO) is a cryptocurrency indicator designed for mean reversion analysis and sentiment assessment. It calculates the ratio of CRYPTO:BTCUSD 's market capitalization to the sum of stablecoins' market capitalization and z-scores the result, offering insights into market sentiment and potential turning points.
Methodology:
The SSRO is calculated as follows-
method ssro(float src, array stblsrc, int len) =>
float ssr = src / stblsrc.sum() // Source of the underlying divided by the sum of stablecoin sources
(ssr - ta.sma(ssr, len)) / ta.stdev(ssr, len) // Z-Score Transformed
This ratio is Z-Scored to provide a standardized measure, allowing users to identify periods of market fear or greed based on the allocation of capital between the underlying and Stablecoins ( CRYPTOCAP:USDT , CRYPTOCAP:USDC , CRYPTO:TUSD , CRYPTOCAP:BUSD , CRYPTOCAP:DAI , CRYPTOCAP:USDD , CRYPTOCAP:FRAX ). The z-scored values indicate potential areas of discount (buying opportunities) or premium (selling opportunities) relative to historical patterns.
Customization:
Underlying Asset: SSRO is customizable to different underlying assets, offering a versatile tool for various cryptocurrencies.
Calculation Length: Users can adjust the length of the calculation, tailoring the indicator to short or long-term analysis.
Visualization: SSRO can be displayed as candles, providing a visual representation of premium and discount areas.
Interpretation:
Market Sentiment: Lower SSRO values may indicate market fear, suggesting a preference for stablecoins as a relatively safer haven for capital. Conversely, higher values may suggest market greed, as more capital is allocated to the underlying asset.
Utility and Use Cases:
1. Mean Reversion Analysis: SSRO identifies potential mean reversion opportunities, guiding traders on optimal entry and exit points.
2. Sentiment Analysis: The indicator provides insights into market sentiment, aiding traders in understanding market dynamics.
3. Macro Analysis: The majority of cryptos follow \ correlate to CRYPTO:BTCUSD , Therefore by assessing premium and discount areas of CRYPTO:BTCUSD relative to the chosen underlying asset, users gain insights into potential market tops and bottoms.
4. Divergence Analysis: SSRO divergence from price trends can signal potential reversals, providing traders with additional confirmation for their decisions.
The Stablecoin Supply Ratio Oscillator is a valuable tool for cryptocurrency traders, offering a nuanced perspective on market sentiment and mean reversion opportunities. Its customization options and visual representation make it a versatile and powerful addition to the crypto analyst's toolkit.
FVG w/ Fibs [QuantVue]The "FVG w/ Fibs" indicator is a trading tool designed to identify and visualize Fair Value Gaps (FVGs) while overlaying two Fibonacci retracement levels.
• Bullish FVG: Occurs when the low of the current bar is higher than the high of two bars ago, and the previous close is higher than the high of two bars ago.
• Bearish FVG: Occurs when the high of the current bar is lower than the low of two bars ago, and the previous close is lower than the low of two bars ago.
The indicator filters these gaps based on user-defined criteria such as the minimum percentage size of the gap.
Once identified, these FVGs are highlighted on the chart using customizable boxes and the 50% and 61.8% (default settings) Fibonacci retracement levels are calculated and drawn based on the size of the identified FVG.
• Dynamically updates and extends the boxes as the price evolves.
• Alerts / visual changes for FVGs that get filled.
• User option for fills by Wicks or Close
• User-customizable settings for box colors, styles, and Fibonacci level appearances
Give this indicator a BOOST and COMMENT your thoughts!
We hope you enjoy.
Cheers!
Inflation-adjusted performanceOVERVIEW
The Inflation-adjusted performance indicator plots an adjusted closing price for the asset
on the main chart by multiplying the asset price by an inflation factor which is derived from CPI-U. The indicator has a `lookback` length, which is used to lookup the CPI-U index value from `lookback` years ago.
The inflation adjusted price is then calculated as `inflationAdjustedPrice = CPIToday / CPIBackThen * currentPrice`
CONCEPTS
This can be a useful tool to assess how an asset has performed as a store of value and inflation hedge over a given period.
The following are the key concepts and user inputs for the oscillator:
Input: The user can specify the lookback period, in years, using the `lookback` attribute on the settings widget. Defult is 13.
CPI Data: The indicator uses CPI data from tradingview's BLS feed.
Inflation Factor: An inflation factor is calculated by dividing today's CPI by the CPI from the lookback period. This factor represents the increase in prices due to inflation over the lookback period.
Inflation-adjusted Price: The offer price of the asset from `lookback` years ago is adjusted for inflation using the calculated inflation factor. This adjusted price represents what the offer price would be today if it had kept up with inflation.
Earnings Yield SpreadThe Earnings Yield Spread might offer an investor some insight into areas of value.
Earnings yield is the ratio of Diluted earnings per share over the trailing twelve months (TTM) to the company’s share price. Earnings yield shows how much the company has earned per share as a percentage of its share price. It shows investors how much yield they are getting in earnings in return for owning the stock at its current share price. (Thank you, TradingView)
One might wonder how the earnings yield on their investment compares to the yield on a US 10 year treasury bond. The Earnings Yield Spread indicator will read above zero if the stock in question earnings yield is higher than US10Y and will read below zero if the stock in question earnings yield is lower than the US10Y.
Earnings yield is relative to the stock in question, so comparisons should be drawn to its own historical reading and not to other symbols.
P/E RatioPlots the P/E Ratio with highest, lowest and average, as well as two ranges, 25-20 & 20-0 considered as the regular P/E Range
Fundamental ScreenerThis indicator is designed to compare the year-over-year earnings and sales growth, as well as the P/E ratio of up to 10 stocks simultaneously .
This provides valuable insights into the fundamental performance of multiple stocks at the same time, allowing traders to quickly identify which stocks are outperforming or underperforming their peers.
The earnings and sales growth figures are calculated on a year-over-year basis , comparing the most recent quarter to the same quarter 1 year ago.
The P/E ratio is a valuation metric that measures a company's stock price relative to its trailing twelve months earnings per share.
By comparing these three key metrics across multiple stocks, traders can quickly identify which stock in a group has superior fundamentals.
Customization
Chose to compare 5 or 10 symbols
Table position, color, and size
Grenblatt Magic FormulaThe magic formula is an investing strategy created by Joel Greenblatt that focuses on finding the best price to buy certain companies in order to maximize returns. When Greenblatt coined the term magic formula investing, his portfolio had a return of 24% from 1998 to 2009.
This means that $10,000 invested at 24% for the period would have turned into just over $1 million. A fund based on the S&P 500 index for the same period would have turned that $10,000 into just under $75,000.1
Note
Bigger returns matter, especially over long periods, due to the power of compounding.
Others who ran their own experiments were not able to duplicate Greenblatt's high returns but still yielded positive results. As a result, investing experts agree that the strategy of magic formula investing outperforms the indexes. In most cases, though, it doesn't seem to beat indexes by as much as Greenblatt indicated when he introduced the concept in his book, The Little Book That Beats the Market.
There are two ratios in the magic formula. The first is the earnings yield: EBIT /EV. This is earnings before interest and taxes divided by enterprise value.A simpler and more common version of this ratio is earnings /price. Greenblatt prefers EBIT over earnings , because EBIT more accurately compares companies with different tax rates. EV is preferred to share price because EV also factors in the company's debt. Therefore, EBIT /EV provides a better picture of overall earnings than earnings /price.
The second ratio is return on capital, which is EBIT /(Net Fixed Assets + Working Capital)
The first ratio looks at earnings before interest and taxes compared to enterprise value. The second ratio focuses on the earnings relative to tangible assets. Many assets listed on the balance sheet depreciate over time as their usefulness is used up. These types of assets are called "fixed assets."
Net fixed assets are fixed assets minus all the accumulated depreciation and any liabilities associated with the asset. This gives a more accurate sense of the real value of a company's assets, compared to just looking at the total asset number on the balance sheet . Working capital is also part of this ratio and is current assets minus current liabilities. This gives a picture of whether the company is likely able to continue operations in the short term.
While the two ratios in the magic formula look small, they actually are computing a lot of data about the inner workings of a company, including:
Earnings
Interest
Tax rates
Equity price
Debt
Depreciation of assets
Current assets
Current liabilities
Overvalued/Undervalued OverlayThis indicator will tell you whether the security you are looking at is overvalued or undervalued using a company's total assets and their market cap. In theory, a company's total assets is everything that they own, which then should technically be how much the company is worth. Therefore, if the company's market cap is higher than their total assets, the indicator will read "Overvalued by X%". However, if the company's market cap is lower than their total assets, the indicator will read "Undervalued by X%". If you have any questions, feel free to let me know. Keep in mind that this indicator should be only used for long-term investing.
Valuation RainbowValuation Rainbow
© danny_peanuts
Stock value based on Book Value, Earnings, Dividends and Money Multiplier
SV = (BVPS + EPS + DPS) * MM
BVPS = Book Value Per Share
EPS = Earnings Per Share
DPS = Dividends Per Share
MM = Money Multiplier - Integer Number from 1,2,3, ... ,7
There are multiple ways of valuing the stock. Book value is traditionally used as the basic valuation since it's calculate the total asset value minus the liabilities of any company. There are valuation based on multiplication of book value, there are valuation based on multiplication of earnings, and valuation based on multiplication of dividends. Here I'm proposing valuation based on all of these combined. So this indicator is measuring stock value based on multiplication of book value plus earning plus dividend per share. Since the money supply could have an multiplication effect so does the stock value could have a multiplication effect. Also notes that some blue chips stock tends to value higher than startup stock due to money is not equally distributed. So for simplicity I will use simple integer number to represent this multiplication effect as rainbow color plots, thus it can be applied to any stock at any given countries. The higher the stock price on valuation bands the most expensive it is and the lower the price on valuation bands the cheaper it is.
DCF ApproximationThe indicator for calculating and visualizing the Discounted Cash Flow (DCF) for a selected stock.
It uses the Weighted Average Cost of Capital (WACC) with a margin of safety and the Free Cash Flow (FCF) calculation for cash flow analysis. The DCF is calculated by summing the discounted annual FCFs over a 10-year period.
The chart color depends on the value of the current price percentage - it turns red when the market price is over valuation, yellow around a fair value, and green for the price under valuation.
This is an early version of the indicator, so I would appreciate your suggestions for improving the code and formulas.
FOREX MASTER PATTERN Value Lines by nnamThe Forex Master Pattern is form of technical analysis that provides a framework for spotting hidden price patterns that reveal the true movement of the market. The Forex Master Pattern Value Lines Indicator helps to identify this Phase 1 contraction of the Forex Master Pattern cycle.
HOW THIS INDICATOR WORKS
This indicator looks for a sustained contraction in price initially indicated by TWO contraction bars in a row, thus detecting a contraction point and a potential new master pattern origin point.
Once a contraction point is detected, a blue box will appear on the chart with a thick solid blue line projecting from its center. These are potential "Points of Origin" and "Value Lines" that institutional traders use to balance their books.
As shown above, when price begins to move (detected by engulfing and/or expansion candles), an Arrow is plotted to the chart identifying a possible expansion.
As shown above, previous Value Lines typically serve as future support / resistance points, however, due to the unique location of these lines, they are not typically identified as support or resistance levels on standard S/R indicators.
Color Coded Candles assist the user in quickly identifying contraction and expansion areas as well as trends away from the value-line. The expansion candles, Up/Down candles, and contraction BARS are all inspired by the STRAT (Rob Smith) and are specifically incorporated into this indicator to assist the user in finding potential reversals during the expansion phase. This helps to avoid the whiplash typically associated with the first phase of Forex Master Pattern.
USER DEFINED SETTINGS
- Line Settings Section -
#Max Lines to Show
This limits or extends the total number of lines shown on the chart. The Default is 12 (minimum is 1, maximum is 499).
#Show Lines on Chart
This setting turns all lines ON or OFF on the chart
#Show Value-Lines on Chart
This setting turns the Value Lines ON or OFF on the chart
#Set Value-Line Width
This setting sets the width of the value-line displayed on the chart
#Only show last value-line on the chart
This setting removes all but the most recent value-line from the chart
- Box Settings Section -
#Show Last Box Only
This setting turns OFF all previous boxes and only shows the most recent contraction box on the chart
- Expansion Area Settings Section -
#Show Expansion Area
This setting turns ON or OFF the expansion area fill
#Show Expansion Guidelines on Chart
This setting turns ON or OFF the guidelines that show the current direction of the price via an extended line.
- Candle Colors Section -
#Color Code the Candles
This setting turns on Color Coding for the Candles which changes the colors of each candle type:
1. Contraction Candle
2. Expansion Candle
3. Up Candle
4. Down Candle
5. Engulfing Candles (engulfing candles override other candle settings if turned ON)
- Engulfing Patterns Section -
#Show Engulfing Patterns
This setting turns ON or OFF engulfing candle plots globally
#Show Bullish Engulfing Candles
This setting allows the user to turn Bullish Engulfing signals ON or OFF
#Show Bearish Engulfing Candles
This setting allows the user to turn Bearish Engulfing signals ON or OFF
I hope you enjoy this indicator and that it provides some value. Please reach out to me with any suggestions or need training on the indicator.
Outliers Detector with N-Sigma Confidence Intervals (TG fork)Display outliers in either value change, volume or volume change that significantly deviate from the past.
This uses the standard deviation calculation and the n-sigmas statistical rule of significance, with 2-sigma (a value of 2) signifying that the observed value is stronger than 95% of past values, and 3-sigma 98.5% of past values, and so on for higher sigma values.
Outliers in price action or in volume can indicate a strong support for the move, and hence potentially more moves in the same direction in the future. Inversely, an insignificant move is less likely to be supported. And of course the stronger, the more support.
This indicator also doubles as a standard volume indicator if volume is selected as the source, but with the option of highlighting outliers.
Bars below significance can be uncolored (gray) to unclutter the visuals.
Differently to almost all other similar indicators, the background highlighting is dynamical, so that all values will be highlighted differently, not just 2-sigma or 3-sigma, but also 4-sigma, 5-sigma, etc, with a different value of transparency.
The dynamical transparency value can be calculated in two ways: either statically proportionally to the n-sigma but capped at 10-sigma, or either as a ratio relative to the highest observed sigma value over the defined lookback period (default: 300).
If you like this indicator, which is an extension of previously published indicators, please give some love to the original authors:
* tvjvzl :
* vnhilton :
This extension, authored by Tartigradia, extends tvjvzl's indi, implements vnhilton's idea of highlighting the background, and go further by adding dynamical background highlighting for any value of sigma, add support for volume and volume change (VolumeDiff) as inputs, add option to uncolor insignificant bars, allow plotting in both directions and more.
Rule Of 20 - Fair Value Estimation by Inflation & Earnings (TG)The Rule Of 20 is a heuristic calculation to find the fair value of an asset or market given its earnings and current inflation.
Its calculation is straightforward: the fair multiple of the price or price-to-earnings ratio of a stock should be 20 minus the rate of inflation.
In math terms: fair_price-to-earnings_ratio = (20 - inflation) ; fair_value = current_price * fair_price-to-earnings_ratio / real_price-to-earnings_ratio
For example, if a stock or index was trading on 11 times earnings and inflation was 2%, then the theory would be that the fair price-to-earnings ratio would be 20-2 = 18, which is much higher than the real price-to-earnings ratio of 11, and hence the asset would be undervalued.
Conversely, a market or company that was trading on 18 times price-to-earnings ration when inflation was 8% was seen as overvalued, because of the fair price-to-earnings ratio being 20-8=12, hence much lower than the real price-to-earnings ratio of 18.
We can then project the delta between the fair PE and real PE onto the asset's value to obtain the projected fair value, which may be a target of future value the asset may reach or hover around.
For example, as of 1st November 2022, SPX stood at 3871.97, with a PE ratio of 20.14 and an inflation in the US of 7.70. Using the Rule Of 20, we find that the fair PE ratio is 20-7.7=12.3, which is much lower than the current PE ratio of 20.14 by 39%! This may indicate a future possibility of a further downside risk by 39% from current valuation levels.
The origins of this rule are unknown, although the legendary US fund manager Peter Lynch is said to have been an active proponent when he was directing the Fidelity’s Magellan fund from 1977 to 1990.
For more infos about the Rule Of 20, reading this article is recommended: www.sharesmagazine.co.uk
This indicator implements the Rule Of 20 on any asset where the Financials are availble to TradingView, and also for the entire SP:SPX index as a way to assess the wider US stock market. Technically, the calculation is a bit different for the latter, as we cannot access earnings of SPX through Financials on TradingView, so we access it using the QUANDL:MULTPL/SP500_PE_RATIO_MONTH ticker instead.
By default are displayed:
current asset value in red
fair asset value according to the Rule Of 20 in white for SPX, or different shades of purple/maroon for other assets. Note that for SPX there is only one calculation, whereas for other assets there are multiple different ways to calculate earnings, so different fair values can be computed.
fair price-to-earnings ratio (PE ratio) in light grey.
real price-to-earnings ratio in darker grey.
This indicator can be used on SP:SPX ticker, and on most NASDAQ:* tickers, since they have Financials integrated in TradingView. Stocks tickers from other exchanges may not provide Financials data, so this indicator won't work then. If this happens, try to find the same ticker on NASDAQ instead.
Note that by default, only the US stock market is considered. If you want to consider stocks or assets in other regions of the world, please change the inflation ticker to a ticker that reflect the target region's inflation.
Also adding a table to ease interpretation was considered, but then the Timeframe MTF parameter would not work, and since the big advantage of this indicator is to allow for historical comparisons, the table was dropped.
Enjoy, and keep in mind that all models are wrong, but some are useful.
Trade safely!
TG
CROCEUsing free cash flow instead of ebit, to be able to evaluate stocks that are not yet profitable.
the formulas are
fcf ttm / (not financial operating working capital - Cash + Net Property Plant and Equipment)
and
fcf yield on Enterprice Value
Example CRWD negative ebit, but cash creation, in this case the expenses in research and development go to affect the ebit.
Capital Asset Pricing Model (CAPM) [Loxx]Capital Asset Pricing Model (CAPM) demonstrates how to calculate the Cost of Equity for an underlying asset using Pine Script. This script will only work on the monthly timeframe. While you can change the default inputs, you should study what CAPM is and how this works before doing so. This indicator pulls various types of data from SPY from various timeframes to calculate risk-free rates, market premiums, and log returns. Alpha and Beta are computed using the regression between underlying asset and SPY. This indicator only calculates on the most recent data. If you wish to change this, you'll have to save the script and make adjustments. A few examples where CAPM is used:
Used as the mu factor Geometric Brownian Motion models for options pricing and forecasting price ranges and decay
Calculating the Weighted Average Cost of Capital
Asset pricing
Efficient frontier
Risk and diversification
Security market line
Discounted Cashflow Analysis
Investment bankers use CAPM to value deals
Account firms use CAPM to verify asset prices and assumptions
Real estate firms use variations of CAPM to value properties
... and more
Details of the calculations used here
Rm is calculated using yearly simple returns data from SPY, typically this is just hard coded as 10%.
Rf is pulled from US 10 year bond yields
Beta and Alpha are pulled form monthly returns data of the asset and SPY
In the past, typically this data is purchased from investments banks whose research arms produce values for beta, alpha, risk free rate, and risk premiums. In 2022 ,you can find free estimates for each parameter but these values might not reflect the most current data or research.
History
The CAPM was introduced by Jack Treynor (1961, 1962), William F. Sharpe (1964), John Lintner (1965) and Jan Mossin (1966) independently, building on the earlier work of Harry Markowitz on diversification and modern portfolio theory. Sharpe, Markowitz and Merton Miller jointly received the 1990 Nobel Memorial Prize in Economics for this contribution to the field of financial economics. Fischer Black (1972) developed another version of CAPM, called Black CAPM or zero-beta CAPM, that does not assume the existence of a riskless asset. This version was more robust against empirical testing and was influential in the widespread adoption of the CAPM.
Usage
The CAPM is used to calculate the amount of return that investors need to realize to compensate for a particular level of risk. It subtracts the risk-free rate from the expected rate and weighs it with a factor – beta – to get the risk premium. It then adds the risk premium to the risk-free rate of return to get the rate of return an investor expects as compensation for the risk. The CAPM formula is expressed as follows:
r = Rf + beta (Rm – Rf) + Alpha
Therefore,
Alpha = R – Rf – beta (Rm-Rf)
Where:
R represents the portfolio return
Rf represents the risk-free rate of return
Beta represents the systematic risk of a portfolio
Rm represents the market return, per a benchmark
For example, assuming that the actual return of the fund is 30, the risk-free rate is 8%, beta is 1.1, and the benchmark index return is 20%, alpha is calculated as:
Alpha = (0.30-0.08) – 1.1 (0.20-0.08) = 0.088 or 8.8%
The result shows that the investment in this example outperformed the benchmark index by 8.8%.
The alpha of a portfolio is the excess return it produces compared to a benchmark index. Investors in mutual funds or ETFs often look for a fund with a high alpha in hopes of getting a superior return on investment (ROI).
The alpha ratio is often used along with the beta coefficient, which is a measure of the volatility of an investment. The two ratios are both used in the Capital Assets Pricing Model (CAPM) to analyze a portfolio of investments and assess its theoretical performance.
To see CAPM in action in terms of calculate WACC, see here for an example: finbox.com
Further reading
en.wikipedia.org
Blockchain Fundamentals - Active Address Sentiment Osc. [CR]Blockchain Fundamentals: Active Address Sentiment Oscillator AASO
Back with another script today, this one is a useful tool in helping to determine bitcoins value. We are looking at 2 data sources: the daily active addresses on the BTC blockchain, and the daily returns of BTC.
THIS INDICATOR WILL ONLY GIVE YOU THE CORRECT RESULTS ON THE DAILY TIMEFRAME
There is an interesting relationship that you can see by comparing the two timeseries. But for us to create a good indicator we first need to normalize the data. So we look at the percent change over the past 28 days for each metric (DAA and price).
THIS INDICATOR WILL ONLY GIVE YOU THE CORRECT RESULTS ON THE DAILY TIMEFRAME
We then calculate standard deviation bands around the DAA metric. We finalize them by averaging the bands over a 28 day period.
When the Price series (yellow line) is higher than the SD bands BTC is considered overvalued or price is overheated. A pullback could be expected soon. When the Price series is below the SD bands BTC is considered undervalued or price is oversold.
THIS INDICATOR WILL ONLY GIVE YOU THE CORRECT RESULTS ON THE DAILY TIMEFRAME
This tool doesnt give signals on the one minute chart or tell you exactly when to buy or sell. BUT what it does do is act as a convenient macro sentiment indicator that is not based completely upon price.
In an attempt to narrow down the really juicy areas, if you seen the background color highlights with white, that means its likely a top or bottom. At the very least on a local sense and many times in a cyclical macro sense as well. It also narrows down the signal to a generally more profitable area.
This indicator is not meant to be used on timeframes other than daily (did I mention that already?). I am lazy and did not code the calculations to be MTF (which is why you have to use on the daily chart). If you want to code this, please forward it on to me and I will post an update with a heartfelt credit to you.
Blockchain Fundamentals: Electricity Cost of BTC [CR] Blockchain Fundamentals: Electricity Cost of BTC
After a hiatus, now a return to publishing tools and scripts for the community. This is my first script in over and year, and I have a number more coming soon as well! (so Stay Tuned!)
This is a simple calculator to estimate the cost of Bitcoin miners to mine one bitcoin. It works on all timeframes (doesnt have to be on daily).
By entering the inputs of total TH's, kWh used, cost of electricity per kWh (in USD cents) we can generate the electricity cost.
But miners also have other costs of operation including HVAC, maintenance, rent, etc. In light of that we include a multiplier that accounts for these extra costs. First, type in what percent of your total operating costs come from the electricity. Then check the enable total cost plot option and you will also see total costs in addition to electricity costs.
Its a simple model and gives anyone curious a starting point for their own testing and research.
Close Combination Lock Style - Visual AppealThis creates a combination style closing price change on each tick.
It has two theme options, one as silver dials for Dark Theme and the other as black dials for White Theme.
We get fixated to watching closing prices on charts and it gets visually daunting. This creates a combination style price change which updates on each tick, which is quite pleasing to the eye.
When new price is above current center line, it shift the above prices showing ▲ arrow, and if new price is lower, it will shift the bottom prices showing ▼ arrow. If there is no change in price between the ticks, it will show =.