modeling_fb_per_cost_discussion
Cost per result (CpR) as the result of several processes…
How should we consider this outcome? At the base level the Cost per Result (‘CpR’) for a ‘segment’ (a particular ad version, audience, campaign, etc), comes from several interrelated processes:
- How much FB charges us for this segment
- Who FB serves this segment to (what types of people, how many)
- How many people in that segment click and then ‘convert’, yielding a result
We could try to model each of these processes, but it could be very involved, and we don’t fully observe or understand the second step, FB’s optimization algorithm.
Rambling about the unit of observation, and a possible multi-equation model
I still want to model “cost per result” (or perhaps better “results per cost”) as a function of the different levers we can pull (audience filters, video content, message content, etc.). But there are challenges in consiring the ‘unit of observation’ and the outcome variability, for statistical inference.
Fundamentally, the data represents many rows of mostly 0’s (no result, no email left) with a few 1’s. Each of these rows has a set of design features; the ‘levers’ above, as well as some other features like demographics and calendar date (although FB makes it difficult/impossible to view everything together.)
We could examine the relationship between the features and the ‘probability an individual yields a result’. ‘Cost’ could be one of those features, in something like a logit model. A transformation of the function $p(result) = a + b_1 cost (b_2 AdVersion + b_3 audience + b_4 AdVersion*audience +… ), perhaps.
But cost (cost per impression) is also a function of some of these characteristics. We could examine the relationship between cost and these features in a separate equation and somehow try to simultaneously estimate these … but it’s challenging.
CpR as a black box…
Alternatively, we could think of the CpR for a segment as just a ‘base outcome to model’, and treat it as a black box. This would suggest we have ‘only one CpR outcome per segment’, and each segment has different characteristics (‘features’ or ‘variables’), some in common. But that discards some important information: the mean values for segments with more observations (here, ‘reach’) can be expected to have less variance (lower standard error), all else equal.
CpR as the average of a lot of black boxes…
We can do something intermediate – taking the aggregation into account, without fully building a structural model of the factors above. Within each segment, we can consider the ‘average cost per result’ outcome for each individual as the expected value of a random draw. Each individual has some ‘cost per impression’, and some ‘probability of a result’. The ratio of these is the individual’s ‘expected cost per result … which we can also abstract as just some random draw. This may be considered as a function of ’all the characteristics of the segment the individual is in’. The CpR for the segment is thus an average of the CpR for all the individuals in the segment, and we can use ‘regression weights’ (technically ‘inverse variance weights’; see discussion in Huntington-Klein’s book here) in our model to reflect this.
Modeling goals/discussion/todo
*Rethinking (5 Aug 2022): Cost per result may not be the best outcome to model as a first pass. We might better model results per impression and put in a cost adjustment later. See
- Present mean/Bayesian updating:
- Overall cost/result
- and for different audiences
- random effects?
- present posterior distribution and intervals
Or a stripped down ‘simulation approach’?
- Model (multivariable regression):
Cost/result as a function of
- campaign (i.e., time of launch)
- message
- video
- audience
- gender
- age
Linear and log-linear
Random effects (how?)
Present a set of estimates for the mean and 80% CI for cost/result for key groups
Modeling ‘cost per result’ and ‘results per dollar’: possible reference literature
Footnotes
Although I am not sure if this is the case; the costs and number of impressions served are determined in a complicated way.↩︎