tally_counter: tally_counter

Description Usage Arguments Value Examples

View source: R/tally.R

Description

This function initiates a new tally counter with the count limit set to the number of rows in the data frame used to interate over. The counter can either increase from zero to the number of rows set or decrease from the number of rows to zero based on the type argument.

Usage

1

Arguments

data

a data frame to be used in the iteration

...

character string argument named type indicating type of counter to use, either adding or subtracting counts

Value

the data frame is returned so that the function is pipe friendly

Examples

1
2
3
4
5
6
7
# Use default decreasing count setting
iris_three<- iris[1:3, ]
tally_counter(iris_three)

# Set increasing count setting
iris_three <- iris[1:3, ]
tally_counter(iris_three, type = "add")

gcfrench/tallyr documentation built on Oct. 8, 2019, 5:17 p.m.