fintech-algorithms

Basic EPS

Install and import

bash
npm install fintech-algorithms
ts
import { calculateBasicEps } from "fintech-algorithms/earnings-and-per-share-analytics/earnings-and-share-foundations/basic-eps";

Signature

calculateBasicEps(input)

Worked example

executed Captured by running this function on the input its own test provides. Real output of real code — but not asserted against a published figure.

Input

input
{
  "entity_id": "EXAMPLE-PLC",
  "period_start": "2025-01-01",
  "period_end": "2025-12-31",
  "as_of": "2026-02-20T16:30:00Z",
  "accounting_framework": "IFRS",
  "statement_scope": "consolidated",
  "currency": "USD",
  "profit_loss_attributable_to_owners": "12500",
  "preference_dividend_adjustment": "500",
  "participating_security_allocation": "0",
  "other_numerator_adjustment": "0",
  "earnings_scale": "1000",
  "weighted_average_ordinary_shares": "6000",
  "share_scale": "1000"
}

Showing 14 of 21 fields.

Call

calculateBasicEps(input)

Returns

object with 19 fields: metric, entity_id, period_start, period_end, as_of, accounting_framework, statement_scope, currency, …

{
  "metric": "basic_earnings_per_ordinary_share",
  "entity_id": "EXAMPLE-PLC",
  "period_start": "2025-01-01",
  "period_end": "2025-12-31",
  "as_of": "2026-02-20T16:30:00Z",
  "accounting_framework": "IFRS",
  "statement_scope": "consolidated",
  "currency": "USD",
  "numerator_policy": "Profit attributable to owners less after-tax preference dividends.",
  "denominator_policy": "IAS 33 weighted-average ordinary shares, retrospectively restated.",
  "earnings_available_to_ordinary_shareholders": "12000000",
  "weighted_average_ordinary_shares_base": "6000000",
  "basic_eps": "2.0000",
  "decimal_places": 4
}

Showing 14 of 19 fields.

Diagrams

Basic EPS — basic eps fraction
Basic EPS — same earnings different shares

Calculation flow

Basic EPS boundary
flowchart TB
  P["Profit or loss attributable to owners"] --> N["Less preference adjustment"]
  S["Participating-security allocation"] --> N
  O["Signed other adjustment"] --> N
  N --> E["Earnings available to ordinary shareholders"]
  W["Restated weighted-average ordinary shares"] --> B["Basic EPS"]
  E --> B
  Q["Potential ordinary shares"] --> D["Diluted EPS — separate topic"]
  B -. "starting point" .-> D
Calculation gates
flowchart LR
  A["Reporting identity and period"] --> B{"Framework and scope declared?"}
  B -- "No" --> X["Reject"]
  B -- "Yes" --> C{"Numerator attribution complete?"}
  C -- "No" --> X
  C -- "Yes" --> D{"Denominator restatement complete?"}
  D -- "No" --> X
  D -- "Yes" --> E["Apply explicit unit scales"]
  E --> F["Divide exact decimals"]
  F --> G["Round by declared policy"]
  G --> H["Basic EPS plus audit diagnostics"]

How it works

This page states the contract — how to call it correctly. The article explains the concept: why it works, and where it breaks.

Read the article →

References

  • IAS 33 Earnings per Share — IFRS Foundation and International Accounting Standards Board
  • FASB Accounting Standards Codification Topic 260 — Financial Accounting Standards Board
  • Farmers & Merchants Bancorp, Inc. 2025 second-quarter Form 10-Q — Farmers & Merchants Bancorp, Inc.; filed with the U.S. Securities and Exchange Commission
  • SEC EDGAR submissions metadata for CIK 0000792966 — U.S. Securities and Exchange Commission
  • Date and Time on the Internet: Timestamps — Internet Engineering Task Force
  • ECMAScript BigInt Objects — Ecma International
  • Python integer numeric type — Python Software Foundation
  • Research notes and limits