# bgbb.PlotTransactionRateHeterogeneity: BG/BB Plot Transaction Rate Heterogeneity In BTYD: Implementing BTYD Models with the Log Sum Exp Patch

## Description

Plots and returns the estimated beta distribution of P (customers' propensities to purchase).

## Usage

 `1` ```bgbb.PlotTransactionRateHeterogeneity(params) ```

## Arguments

 `params` BG/BB parameters - a vector with alpha, beta, gamma, and delta, in that order. Alpha and beta are unobserved parameters for the beta-Bernoulli transaction process. Gamma and delta are unobserved parameters for the beta-geometric dropout process.

## Details

This returns the distribution of each customer's Bernoulli parameter, which determines the level of their purchasing (using the BG/BB assumption that purchasing on the individual level can be modeled with a Bernoulli distribution).

## Value

Distribution of customers' propensities to purchase.

## Examples

 ```1 2 3 4``` ```params <- c(1.2, 0.75, 0.66, 2.78) bgbb.PlotTransactionRateHeterogeneity(params) params <- c(0.2, 1.5, 3.2, 6) bgbb.PlotTransactionRateHeterogeneity(params) ```

### Example output

```Loading required package: hypergeo
[1] 0.0000000 0.3475826 0.4002823 0.4352093 0.4621799 0.4845404 0.5038661
[8] 0.5210336 0.5365843 0.5508775 0.5641652 0.5766309 0.5884133 0.5996195
[15] 0.6103344 0.6206266 0.6305522 0.6401580 0.6494832 0.6585615 0.6674218
[22] 0.6760892 0.6845856 0.6929306 0.7011416 0.7092340 0.7172220 0.7251184
[29] 0.7329348 0.7406822 0.7483704 0.7560090 0.7636066 0.7711715 0.7787117
[36] 0.7862346 0.7937475 0.8012575 0.8087712 0.8162954 0.8238366 0.8314012
[43] 0.8389957 0.8466265 0.8543000 0.8620227 0.8698012 0.8776422 0.8855525
[50] 0.8935391 0.9016093 0.9097706 0.9180308 0.9263980 0.9348807 0.9434878
[57] 0.9522288 0.9611136 0.9701528 0.9793577 0.9887401 0.9983129 1.0080900
[64] 1.0180862 1.0283176 1.0388014 1.0495568 1.0606042 1.0719664 1.0836681
[71] 1.0957366 1.1082023 1.1210988 1.1344635 1.1483384 1.1627708 1.1778142
[78] 1.1935293 1.2099854 1.2272625 1.2454531 1.2646650 1.2850249 1.3066831
[85] 1.3298196 1.3546523 1.3814481 1.4105383 1.4423415 1.4773953 1.5164056
[92] 1.5603231 1.6104675 1.6687411 1.7380195 1.8229263 1.9315508 2.0798926
[99] 2.3065061 2.7484885       Inf
[1]        Inf 8.84649821 5.05525233 3.63615728 2.87369995 2.39133046
[7] 2.05587508 1.80766038 1.61575579 1.46244818 1.33682652 1.23178427
[13] 1.14248402 1.06551297 0.99839085 0.93926957 0.88674236 0.83971847
[19] 0.79733847 0.75891550 0.72389369 0.69181808 0.66231250 0.63506312
[25] 0.60980587 0.58631691 0.56440516 0.54390646 0.52467892 0.50659929
[31] 0.48955987 0.47346621 0.45823501 0.44379259 0.43007345 0.41701919
[37] 0.40457755 0.39270162 0.38134913 0.37048193 0.36006543 0.35006824
[43] 0.34046178 0.33121993 0.32231882 0.31373656 0.30545301 0.29744964
[49] 0.28970933 0.28221625 0.27495574 0.26791418 0.26107888 0.25443803
[55] 0.24798060 0.24169624 0.23557528 0.22960859 0.22378761 0.21810424
[61] 0.21255082 0.20712009 0.20180515 0.19659941 0.19149660 0.18649068
[67] 0.18157586 0.17674654 0.17199731 0.16732290 0.16271815 0.15817801
[73] 0.15369750 0.14927167 0.14489557 0.14056422 0.13627260 0.13201556
[79] 0.12778782 0.12358386 0.11939793 0.11522390 0.11105522 0.10688476
[85] 0.10270471 0.09850636 0.09427989 0.09001400 0.08569555 0.08130891
[91] 0.07683512 0.07225068 0.06752561 0.06262049 0.05748137 0.05203073
[97] 0.04614948 0.03963666 0.03209874 0.02251364 0.00000000
```

BTYD documentation built on Nov. 18, 2021, 1:10 a.m.