Skip to contents

Smallest balance first. From the Managing debt chapter.

Usage

order_snowball(debts)

Arguments

debts

A data frame with a numeric balance column.

Value

debts, reordered by balance from smallest to largest.

Examples

debts <- data.frame(
  name = c("Card A", "Card B", "Card C"),
  balance = c(1000, 5000, 2000),
  apr = c(0.18, 0.24, 0.15)
)
order_snowball(debts)
#>     name balance  apr
#> 1 Card A    1000 0.18
#> 3 Card C    2000 0.15
#> 2 Card B    5000 0.24