Calculate the Price-to-Earnings ratio for a stock.
Your PE Ratio will appear here.
What is the PE Ratio?
The Price-to-Earnings (PE) ratio is a fundamental valuation metric used by investors and analysts to compare the relative worth of a company's stock. It essentially tells you how much investors are willing to pay for each dollar of a company's earnings.
How is the PE Ratio Calculated?
The formula for the PE ratio is straightforward:
PE Ratio = Current Share Price / Earnings Per Share (EPS)
Where:
Current Share Price: The current market price of one share of the company's stock.
Earnings Per Share (EPS): The portion of a company's profit allocated to each outstanding share of common stock. It is calculated as: Net Income - Preferred Dividends / Average Outstanding Common Shares. For simplicity in this calculator, we use the provided EPS value.
Interpreting the PE Ratio
The PE ratio can be interpreted in several ways:
High PE Ratio: A high PE ratio might suggest that investors expect higher earnings growth in the future compared to companies with lower PE ratios. However, it could also indicate that the stock is overvalued.
Low PE Ratio: A low PE ratio might signal that a stock is undervalued, or it could mean that investors have lower expectations for the company's future growth or perceive higher risk.
Industry Comparison: It's crucial to compare a company's PE ratio to those of its competitors within the same industry, as different industries naturally have different average PE ratios.
Historical Comparison: Comparing a company's current PE ratio to its own historical PE ratios can provide insights into whether the stock is trading at a premium or discount relative to its past.
Example Calculation
Let's say a company's stock is currently trading at $50.75 per share, and its Earnings Per Share (EPS) for the last twelve months was $2.50.
Using the formula:
PE Ratio = $50.75 / $2.50 = 20.30
In this case, the PE ratio is 20.30. This means investors are willing to pay $20.30 for every $1 of the company's earnings.
Limitations
While useful, the PE ratio has limitations:
It can be misleading for companies with negative earnings (resulting in a negative or non-existent PE ratio).
It doesn't account for a company's debt.
EPS can be manipulated through accounting practices.
Therefore, it should be used in conjunction with other financial metrics for a comprehensive analysis.
function calculatePEratio() {
var sharePriceInput = document.getElementById("sharePrice");
var epsInput = document.getElementById("eps");
var resultDiv = document.getElementById("result");
var sharePrice = parseFloat(sharePriceInput.value);
var eps = parseFloat(epsInput.value);
// Input validation
if (isNaN(sharePrice) || isNaN(eps)) {
resultDiv.innerHTML = "Please enter valid numbers for both fields.";
resultDiv.style.color = "red";
return;
}
if (sharePrice < 0 || eps < 0) {
resultDiv.innerHTML = "Share Price and EPS cannot be negative.";
resultDiv.style.color = "red";
return;
}
if (eps === 0) {
resultDiv.innerHTML = "EPS cannot be zero for PE ratio calculation. The stock may be overvalued or unprofitable.";
resultDiv.style.color = "#ff9800"; /* Orange for warning */
return;
}
var peRatio = sharePrice / eps;
// Format the result to two decimal places
var formattedPE = peRatio.toFixed(2);
resultDiv.innerHTML = "Your PE Ratio is: " + formattedPE + "";
resultDiv.style.color = "#004a99"; /* Professional blue */
}