update_item: Updates a budget item

Description Usage Arguments Value Examples

View source: R/update_item.R

Description

update_item returns an updated budget item.

Usage

1
update_item(item, name, amount, day, recurring)

Arguments

item

The budget item to be updated.

name

The new name for the budget item (if applicable).

amount

The new amount for the budget item (if applicable).

day

The new day for the budget item (if applicable).

recurring

The new recurring status for the budget item (if applicable).

Value

The output of update_item is a new budget item with the specified updates.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
# Create a paycheck item
paycheck <- create_item( name = "Paycheck"
                       , amount = 1000
                       , day = "2016-01-01"
                       , recurring = "monthly"
                       )
# Inspect
paycheck

# Update the paycheck amount
paycheck <- update_item( paycheck
                       , amount = 1500
                       )
# Inspect
paycheck

derek-damron/budgetr documentation built on Aug. 11, 2020, 2:41 a.m.