gave_to_fund: Giving to fund(s)

View source: R/converter-gave-to-fund.R

gave_to_fundR Documentation

Giving to fund(s)

Description

Find entities who have given to a custom list of funds

Usage

gave_to_fund(..., at_least = 0.01, from = NULL, to = NULL)

Arguments

...

Allocation code(s) or a disco definition of type allocation_code

at_least

minimum total giving (defaults to .01)

from

begin and end dates (gave between those dates). Enter as an integer of the form YYYYMMDD

to

begin and end dates (gave between those dates). Enter as an integer of the form YYYYMMDD

Details

from and to are optional, not entering them will leave that end of the date range open. So for example a year-to-date cutoff can be achieved by using from but not to. Leaving both blank will look for donors at any time. Giving is aggregated to all funds specified in the ... – so you're not looking for someone who gave at_least to one of the funds on the list, but rather someone who gave in total at_least to all/any of the funds that appear on that list.

Value

A discoveryengine list definition of type entity_id

See Also

gave_to_area, gave_to_department, fund_text_contains, funds

Examples

## find funds supporting diversity
diversity_funds = fund_text_contains("diversity")

## donors to those funds
gave_to_fund(diversity_funds)

## just donors over $10K to those funds
gave_to_fund(diversity_funds, at_least = 10000)

## just donors over $10K during calendar year 2015
gave_to_fund(diversity_funds, at_least = 10000, from = 20150101, to = 20151231)

## donors who had given at least $100K to diversity funds before 2012
gave_to_fund(diversity_funds, at_least = 100000, to = 20111231)

## can also provide individual allocation IDs as-is
gave_to_fund(FH2031000, FW6644000, at_least = 1000)


tarakc02/discoveryengine documentation built on Sept. 26, 2023, 12:17 a.m.