| addActivity | R Documentation | 
Add a new entry to the account.
addActivity(object, ...) <- value
## S3 replacement method for class 'butilsAccount'
addActivity(
  object,
  involved = NULL,
  type = as.character(NA),
  date = as.Date(NA),
  note = "",
  label = NULL,
  ...
) <- value
| object | the account. | 
| ... | ignored. | 
| value | [numeric] a named vector describing name paid what. | 
| involved | [vector of characters] who was involved in the activity? | 
| type | [character] the name of the activity. | 
| date | [date, d-m-Y] the date at which the activity happen. | 
| note | [character] additional text. | 
| label | [label] a label associated with the activity. When displayed activities are sorted by labels. | 
#### Create an account ####
myAcc <- createAccount()
#### Ease input with short names ####
addNickName(myAcc) <- list("Brice Ozenne" = "Brice",
                           "Sebastian Holst" = c("Seb","Sebastian"))
#### Add activity paid by one person for others ####
addActivity(myAcc, involved = c("Brice","Sebastian"), type = "Court") <- c("Sebastian" = 200)
#### Add expense, i.e. activity paid by nobody ####
addActivity(myAcc, involved = c("Brice","Sebastian"), type = "Shuttlecock") <- 100
#### Add contribution from one member ####
addActivity(myAcc, type = "Shuttlecock") <- c("Brice" = 100)
####
myAcc
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.