# Custom MARGIN() Function

Extends the engine with a user-defined `MARGIN(cost, price)` via `registerFunction`, calls it from a formula for each SKU, and uses `getDependencies("=MARGIN(A1,B1)")` to show the engine correctly reports the two cells the formula reads.
