recieve_interest: Recieve Interest payment

Description Usage Arguments Value Examples

View source: R/Income.R

Description

Function updates cash balance and adds record to activity and income records

Usage

1
recieve_interest(pobj, date = Sys.Date(), amount, desc = "")

Arguments

pobj

portfolio object

date

date of interest payment. Date type

amount

dollar amount of interest payment. numeric type

desc

optional description of interest. string type

Value

updated portfolio object

Examples

1
2
3
4
5
library(tidyverse)
portfolio("new_port") %>%
make_deposit(amount = 2000) %>%
make_buy(symbol = "SPY", quantity = 10, price = 100) %>%
recieve_interest(amount = 5)

chrishaarstick/madstork documentation built on Jan. 3, 2022, 8:34 p.m.