Friedman Test Calculator
Enter the rank sums per treatment and the number of subjects to compute the Friedman statistic.
Result
How it is calculated
You supply the rank sum of each treatment, separated by commas, and the number of subjects n (a whole number). The number of treatments k is the count of values you list, at least 2. The statistic is χ²F = 12 / (n × k × (k + 1)) × ΣRj² − 3 × n × (k + 1), where Rj is the sum of ranks for treatment j, and the degrees of freedom are k − 1. The tool returns χ²F to four decimals plus df, k and n. It checks the rank sums: each must lie between n and n × k, and together they must add up to n × k × (k + 1) / 2, otherwise no result is shown. Fractional values from tied ranks are accepted when they add up. It does not rank raw data, correct the statistic for ties or give a p-value: compare it with a chi-square critical value for k − 1 degrees of freedom.
Worked example
Ten subjects each rate three treatments, and ranking within each subject gives rank sums of 14, 20 and 26. Check: 14 + 20 + 26 = 60 = 10 × 3 × 4 / 2. Sum of squares: 196 + 400 + 676 = 1,272. Constant: 12 / (10 × 3 × 4) = 0.1, so 0.1 × 1,272 = 127.2. Subtract 3 × 10 × 4 = 120. The statistic is 7.2000 with k − 1 = 2 degrees of freedom. The usual 5% chi-square critical value for 2 degrees of freedom is 5.991, so 7.2 is larger and suggests the treatments differ.
Common mistakes
- Entering the raw scores or the mean ranks instead of rank sums. The field wants the total of ranks per treatment, so with 10 subjects and 3 treatments each value lies between 10 and 30.
- Ranking in the wrong direction or across subjects. Ranks 1 to k are assigned within each subject (each row), then added up down each treatment column.
- Entering rank sums that do not add up to n × k × (k + 1) / 2. For 10 subjects and 3 treatments they must total 60; a list like 14, 20, 30 shows no result, which usually means an arithmetic slip.
- Using spaces or semicolons as separators. Only commas split the list, and 14 20 26 is read as one value, so there is no result.
- Expecting a p-value or tie correction. If many scores tie within subjects, the plain statistic is slightly off, and you still need a chi-square table to interpret it.
About this calculator
The Friedman test is a non-parametric alternative to the repeated-measures ANOVA, used to detect whether there are significant differences across three or more related conditions or treatments measured on the same subjects, without assuming the data is normally distributed. Instead of working with raw values, the test ranks each subject’s scores across the treatments (1 through k for each row), sums the ranks for each treatment across all subjects to get rank sums R_j, and combines these into the test statistic χ²_F = [12 / (n·k·(k+1))] × Σ(R_j²) − 3n(k+1), where n is the number of subjects and k is the number of treatments.
Under the null hypothesis of no real difference between treatments, this statistic approximately follows a chi-square distribution with k−1 degrees of freedom, so the computed value is compared against a chi-square critical value or converted to a p-value to decide whether to reject the null. Biostatisticians, psychologists, and researchers in any field with repeated-measures or matched-subjects designs use the Friedman test when data is ordinal, skewed, or has outliers that would violate the normality assumption behind repeated-measures ANOVA — for example, comparing the same panel of judges’ rankings of several products. This calculator computes the Friedman statistic χ²_F and the degrees of freedom (k−1) from entered rank sums and the number of subjects; it does not return a p-value, so compare χ²_F with a chi-square critical value for those degrees of freedom (or look up the p-value in statistical software). You rank each subject's scores and sum the ranks per treatment yourself before entering them, as a comma-separated list.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments