Save user willingness input from prompts on maps and quiz tab
Usage
save_willingness(
db,
source,
asc_bias,
event_size,
answer,
ip,
vacc_imm,
latitude,
longitude,
utm_source = "NULL",
utm_medium = "NULL",
utm_content = "NULL",
utm_campaign = "NULL"
)
Arguments
- db
Database or pool object
- source
Where is willingness being be asked, e.g. "game" or "map"
- asc_bias
Ascertainment bias when asked on map, set to -1 for other uses
- event_size
Event size when asked on map, set to -1 for other uses
- answer
Willingness answer, should come from the willingness scale
- ip
User ip if known, typically from `globals$ip()``
- vacc_imm
Vaccine immunity overlay setting if from map
- latitude
User latitude, 0 if unknown. Typically from `globals$latitude()`
- longitude
User longitude, 0 if unknown. Typically from `globals$longitude()`
- utm_source
`utm_source=` value from query string or 'NULL'
- utm_medium
`utm_medium=` value from query string or 'NULL'
- utm_content
`utm_content=` value from query string or 'NULL'
- utm_campaign
`utm_campaign=` value from query string or 'NULL'