Calculate epidemiology incidence rates and cumulative incidence.
(Total population count or person-years)
Per 100 (Percentage %)
Per 1,000
Per 10,000
Per 100,000
Calculated Incidence Rate:
0.00
function calculateIncidenceRate() {
// Get input values using var
var newCasesInput = document.getElementById('newCases');
var populationInput = document.getElementById('population');
var multiplierInput = document.getElementById('multiplier');
var timePeriodInput = document.getElementById('timePeriod');
var resultBox = document.getElementById('resultBox');
var finalResultDisplay = document.getElementById('finalResult');
var resultExplanationDisplay = document.getElementById('resultExplanation');
// Parse values
var cases = parseFloat(newCasesInput.value);
var population = parseFloat(populationInput.value);
var multiplier = parseFloat(multiplierInput.value);
var timeLabel = timePeriodInput.value.trim();
// Validation
if (isNaN(cases) || isNaN(population) || population <= 0 || cases < 0) {
alert("Please enter valid positive numbers for New Cases and Population.");
return;
}
// Calculation logic
// Formula: (New Cases / Population at Risk) * Multiplier
var rawRate = (cases / population);
var calculatedRate = rawRate * multiplier;
// Formatting the result (limit decimals for readability)
// If the number is an integer, show as integer, else max 2 decimals
var formattedResult = Number.isInteger(calculatedRate) ? calculatedRate : calculatedRate.toFixed(2);
// Determine label for the multiplier
var perLabel = "";
if (multiplier === 100) perLabel = "% (Per 100)";
else if (multiplier === 1000) perLabel = "per 1,000";
else if (multiplier === 10000) perLabel = "per 10,000";
else if (multiplier === 100000) perLabel = "per 100,000";
// Update DOM
resultBox.style.display = 'block';
finalResultDisplay.innerHTML = formattedResult + " " + perLabel + "";
var explanation = "This means there are " + formattedResult + " new cases for every " + multiplier.toLocaleString() + " people (or person-time units) at risk";
if (timeLabel !== "") {
explanation += " " + timeLabel;
}
explanation += ".";
resultExplanationDisplay.innerHTML = explanation;
}
How Do You Calculate the Incidence Rate?
In epidemiology, the Incidence Rate is a crucial metric used to measure the frequency of new cases of a disease or event occurring in a specific population over a defined period. Unlike prevalence, which looks at existing cases, incidence focuses strictly on new occurrences, making it vital for tracking disease outbreaks and assessing risk.
The Incidence Rate Formula
The basic formula for calculating incidence rate (or incidence proportion) is:
Incidence Rate = (New Cases / Population at Risk) × Multiplier
Where:
New Cases: The count of new disease onsets or events during the study period.
Population at Risk: The total population capable of developing the disease. Alternatively, in more advanced studies, this is replaced by "Person-Time" (e.g., person-years) to account for individuals entering or leaving the study at different times.
Multiplier: A standardizing number (typically 1,000, 10,000, or 100,000) used to make the result readable and comparable.
Incidence Proportion vs. Incidence Density
There are two primary ways to calculate incidence, depending on your data:
Cumulative Incidence (Incidence Proportion): Measures the risk of developing a disease over a specific time period. It uses the population size at the start of the interval as the denominator. This is interpreted as a probability (e.g., "3% risk over 5 years").
Incidence Rate (Incidence Density): Uses "person-time" as the denominator. This is more precise for dynamic populations where people are observed for different lengths of time. The result is often expressed as "Cases per 1,000 person-years."
Example Calculation
Imagine a study monitoring a town of 50,000 people for the flu over the course of one year. During that year, 250 people are diagnosed with the flu.
To calculate the incidence rate per 1,000 population:
Calculation: (250 / 50,000) = 0.005
Standardization: 0.005 × 1,000 = 5
Result: The incidence rate is 5 cases per 1,000 people per year.
Why the Multiplier Matters
Raw incidence numbers (like 0.00045) are difficult to communicate to the public. By applying a multiplier (usually 100,000 for rare diseases or 1,000 for common ones), health officials transform abstract decimals into understandable "counts per population." This allows for easier comparison between different regions or countries with vastly different population sizes.