Model run by stephane.hess using Apollo 0.3.6 on R 4.5.1 for Darwin. Please acknowledge the use of Apollo by citing Hess & Palma (2019) DOI 10.1016/j.jocm.2019.100170 www.ApolloChoiceModelling.com Model name : EL Model description : Exploded logit model on drug choice data Model run at : 2025-09-19 11:47:14.660215 Estimation method : bgw Estimation diagnosis : Relative function convergence Optimisation diagnosis : Maximum found hessian properties : Negative definite maximum eigenvalue : -141.222263 reciprocal of condition number : 1.47431e-07 Number of individuals : 1000 Number of rows in database : 10000 Number of modelled outcomes : 10000 Number of cores used : 1 Model without mixing LL(start) : -31780.54 LL at equal shares, LL(0) : -31780.54 LL at observed shares, LL(C) : NA LL(final) : -27152.53 Rho-squared vs equal shares : 0.1456 Adj.Rho-squared vs equal shares : 0.1452 Rho-squared vs observed shares : Not applicable Adj.Rho-squared vs observed shares : Not applicable AIC : 54335.06 BIC : 54443.21 Estimated parameters : 15 Time taken (hh:mm:ss) : 00:00:6.19 pre-estimation : 00:00:0.74 estimation : 00:00:1.53 post-estimation : 00:00:3.93 Iterations : 8 Unconstrained optimisation. Estimates: Estimate s.e. t.rat.(0) Rob.s.e. Rob.t.rat.(0) b_brand_Artemis 0.000000 NA NA NA NA b_brand_Novum -0.285159 0.02477 -11.514 0.02468 -11.554 b_brand_BestValue -0.562462 0.04616 -12.186 0.04792 -11.738 b_brand_Supermarket -0.285311 0.04754 -6.001 0.05232 -5.453 b_brand_PainAway -1.158671 0.04810 -24.091 0.05077 -22.823 b_country_CH 0.585685 0.03206 18.268 0.03154 18.570 b_country_DK 0.283669 0.03045 9.315 0.03043 9.321 b_country_USA 0.000000 NA NA NA NA b_country_IND -0.279738 0.04067 -6.878 0.04195 -6.669 b_country_RUS -0.851886 0.04323 -19.708 0.04277 -19.918 b_country_BRA -0.612791 0.04213 -14.544 0.04312 -14.211 b_char_standard 0.000000 NA NA NA NA b_char_fast 0.708284 0.02285 30.997 0.02259 31.360 b_char_double 1.120313 0.03127 35.828 0.03013 37.180 b_risk -0.001533 4.323e-05 -35.465 4.264e-05 -35.954 b_price -0.703403 0.01504 -46.768 0.01437 -48.944 scale_1 1.000000 NA NA NA NA scale_2 0.760858 0.02051 37.100 0.01991 38.223 scale_3 0.455239 0.01844 24.687 0.01832 24.846 Overview of choices for EL model component, stage 1: alt1 alt2 alt3 alt4 Times available 10000.00 10000.00 10000.00 10000.00 Times chosen 3403.00 3546.00 1517.00 1534.00 Percentage chosen overall 34.03 35.46 15.17 15.34 Percentage chosen when available 34.03 35.46 15.17 15.34 Overview of choices for EL model component, stage 2: alt1 alt2 alt3 alt4 Times available 6597.00 6454.00 8483.00 8466.00 Times chosen 2983.00 2855.00 2106.00 2056.00 Percentage chosen overall 29.83 28.55 21.06 20.56 Percentage chosen when available 45.22 44.24 24.83 24.29 Overview of choices for EL model component, stage 3: alt1 alt2 alt3 alt4 Times available 3614.00 3599.00 6377.00 6410.00 Times chosen 2083.00 2054.00 2895.00 2968.00 Percentage chosen overall 20.83 20.54 28.95 29.68 Percentage chosen when available 57.64 57.07 45.40 46.30 Classical covariance matrix: b_brand_Novum b_brand_BestValue b_brand_Supermarket b_brand_Novum 6.1332e-04 3.2145e-04 3.6402e-04 b_brand_BestValue 3.2145e-04 0.002130 0.001581 b_brand_Supermarket 3.6402e-04 0.001581 0.002260 b_brand_PainAway 3.4618e-04 0.001502 0.001507 b_country_CH -5.288e-05 4.3465e-04 4.7111e-04 b_country_DK -4.197e-05 4.1265e-04 4.5278e-04 b_country_IND -2.465e-05 -7.9547e-04 -8.3113e-04 b_country_RUS -9.116e-06 -7.6580e-04 -8.3742e-04 b_country_BRA 3.077e-06 -7.2622e-04 -8.7453e-04 b_char_fast -9.086e-06 -7.658e-06 6.077e-05 b_char_double 3.312e-05 2.3848e-04 3.1963e-04 b_risk 3.810e-08 -2.729e-07 -4.007e-07 b_price 3.255e-05 2.1139e-04 1.7385e-04 scale_2 2.770e-05 4.529e-05 -3.288e-05 scale_3 1.990e-06 -2.279e-05 -6.806e-05 b_brand_PainAway b_country_CH b_country_DK b_brand_Novum 3.4618e-04 -5.288e-05 -4.197e-05 b_brand_BestValue 0.001502 4.3465e-04 4.1265e-04 b_brand_Supermarket 0.001507 4.7111e-04 4.5278e-04 b_brand_PainAway 0.002313 3.3832e-04 3.7164e-04 b_country_CH 3.3832e-04 0.001028 4.7690e-04 b_country_DK 3.7164e-04 4.7690e-04 9.2729e-04 b_country_IND -7.1205e-04 -5.259e-05 1.771e-05 b_country_RUS -6.0253e-04 -9.654e-05 -3.264e-05 b_country_BRA -6.6709e-04 -1.1942e-04 -5.661e-05 b_char_fast -1.2453e-04 1.0082e-04 5.980e-05 b_char_double 9.902e-05 1.2546e-04 4.637e-05 b_risk 1.125e-07 -1.907e-07 -9.640e-08 b_price 2.9726e-04 -9.112e-05 -3.467e-05 scale_2 2.2527e-04 -1.0046e-04 -5.211e-05 scale_3 1.0219e-04 -5.989e-05 -3.247e-05 b_country_IND b_country_RUS b_country_BRA b_brand_Novum -2.465e-05 -9.116e-06 3.077e-06 b_brand_BestValue -7.9547e-04 -7.6580e-04 -7.2622e-04 b_brand_Supermarket -8.3113e-04 -8.3742e-04 -8.7453e-04 b_brand_PainAway -7.1205e-04 -6.0253e-04 -6.6709e-04 b_country_CH -5.259e-05 -9.654e-05 -1.1942e-04 b_country_DK 1.771e-05 -3.264e-05 -5.661e-05 b_country_IND 0.001654 8.5260e-04 8.6247e-04 b_country_RUS 8.5260e-04 0.001868 8.9457e-04 b_country_BRA 8.6247e-04 8.9457e-04 0.001775 b_char_fast -8.535e-05 -1.5088e-04 -1.1458e-04 b_char_double -8.209e-05 -1.6333e-04 -1.4097e-04 b_risk 1.329e-07 3.557e-07 1.948e-07 b_price 4.684e-05 1.0955e-04 1.0067e-04 scale_2 5.975e-05 2.0239e-04 1.3018e-04 scale_3 7.032e-05 1.5076e-04 1.0087e-04 b_char_fast b_char_double b_risk b_brand_Novum -9.086e-06 3.312e-05 3.810e-08 b_brand_BestValue -7.658e-06 2.3848e-04 -2.729e-07 b_brand_Supermarket 6.077e-05 3.1963e-04 -4.007e-07 b_brand_PainAway -1.2453e-04 9.902e-05 1.125e-07 b_country_CH 1.0082e-04 1.2546e-04 -1.907e-07 b_country_DK 5.980e-05 4.637e-05 -9.640e-08 b_country_IND -8.535e-05 -8.209e-05 1.329e-07 b_country_RUS -1.5088e-04 -1.6333e-04 3.557e-07 b_country_BRA -1.1458e-04 -1.4097e-04 1.948e-07 b_char_fast 5.2214e-04 3.3295e-04 -2.356e-07 b_char_double 3.3295e-04 9.7775e-04 -2.819e-07 b_risk -2.356e-07 -2.819e-07 1.869e-09 b_price -9.631e-05 -1.2399e-04 2.204e-07 scale_2 -1.4319e-04 -1.8358e-04 4.103e-07 scale_3 -8.417e-05 -9.480e-05 3.078e-07 b_price scale_2 scale_3 b_brand_Novum 3.255e-05 2.770e-05 1.990e-06 b_brand_BestValue 2.1139e-04 4.529e-05 -2.279e-05 b_brand_Supermarket 1.7385e-04 -3.288e-05 -6.806e-05 b_brand_PainAway 2.9726e-04 2.2527e-04 1.0219e-04 b_country_CH -9.112e-05 -1.0046e-04 -5.989e-05 b_country_DK -3.467e-05 -5.211e-05 -3.247e-05 b_country_IND 4.684e-05 5.975e-05 7.032e-05 b_country_RUS 1.0955e-04 2.0239e-04 1.5076e-04 b_country_BRA 1.0067e-04 1.3018e-04 1.0087e-04 b_char_fast -9.631e-05 -1.4319e-04 -8.417e-05 b_char_double -1.2399e-04 -1.8358e-04 -9.480e-05 b_risk 2.204e-07 4.103e-07 3.078e-07 b_price 2.2621e-04 1.2664e-04 6.474e-05 scale_2 1.2664e-04 4.2059e-04 1.0488e-04 scale_3 6.474e-05 1.0488e-04 3.4006e-04 Robust covariance matrix: b_brand_Novum b_brand_BestValue b_brand_Supermarket b_brand_Novum 6.0912e-04 2.4062e-04 3.0281e-04 b_brand_BestValue 2.4062e-04 0.002296 0.001846 b_brand_Supermarket 3.0281e-04 0.001846 0.002738 b_brand_PainAway 2.9482e-04 0.001728 0.001833 b_country_CH -1.0778e-04 3.4239e-04 3.8838e-04 b_country_DK -4.997e-05 2.9718e-04 3.7601e-04 b_country_IND 3.094e-05 -7.7592e-04 -8.5059e-04 b_country_RUS 4.259e-05 -7.3426e-04 -8.5627e-04 b_country_BRA 7.290e-05 -7.3531e-04 -9.1809e-04 b_char_fast -5.567e-05 -2.408e-05 6.458e-05 b_char_double -2.982e-05 1.8279e-04 2.9726e-04 b_risk 5.124e-08 -2.730e-07 -4.403e-07 b_price 4.015e-05 1.6914e-04 1.2864e-04 scale_2 5.029e-05 -1.754e-05 -1.3613e-04 scale_3 3.783e-05 -1.617e-05 -4.823e-05 b_brand_PainAway b_country_CH b_country_DK b_brand_Novum 2.9482e-04 -1.0778e-04 -4.997e-05 b_brand_BestValue 0.001728 3.4239e-04 2.9718e-04 b_brand_Supermarket 0.001833 3.8838e-04 3.7601e-04 b_brand_PainAway 0.002577 2.8230e-04 3.1969e-04 b_country_CH 2.8230e-04 9.9472e-04 4.5409e-04 b_country_DK 3.1969e-04 4.5409e-04 9.2617e-04 b_country_IND -6.5323e-04 -4.551e-05 2.089e-05 b_country_RUS -5.9950e-04 -1.3508e-04 -1.927e-05 b_country_BRA -6.2963e-04 -9.888e-05 -5.600e-05 b_char_fast -1.0369e-04 1.1822e-04 5.871e-05 b_char_double 4.283e-05 1.0981e-04 2.142e-05 b_risk 3.460e-08 -1.619e-07 -6.583e-08 b_price 2.5632e-04 -9.148e-05 -3.682e-05 scale_2 1.4779e-04 -1.2373e-04 -5.683e-05 scale_3 9.148e-05 -6.625e-05 -5.965e-05 b_country_IND b_country_RUS b_country_BRA b_brand_Novum 3.094e-05 4.259e-05 7.290e-05 b_brand_BestValue -7.7592e-04 -7.3426e-04 -7.3531e-04 b_brand_Supermarket -8.5059e-04 -8.5627e-04 -9.1809e-04 b_brand_PainAway -6.5323e-04 -5.9950e-04 -6.2963e-04 b_country_CH -4.551e-05 -1.3508e-04 -9.888e-05 b_country_DK 2.089e-05 -1.927e-05 -5.600e-05 b_country_IND 0.001759 8.3212e-04 9.4536e-04 b_country_RUS 8.3212e-04 0.001829 9.6153e-04 b_country_BRA 9.4536e-04 9.6153e-04 0.001860 b_char_fast -9.460e-05 -1.8633e-04 -1.5093e-04 b_char_double -1.2918e-04 -2.1139e-04 -2.0051e-04 b_risk 2.012e-07 3.905e-07 2.407e-07 b_price 6.887e-05 1.4061e-04 1.1575e-04 scale_2 1.2427e-04 2.2114e-04 1.6614e-04 scale_3 5.879e-05 1.4891e-04 1.0220e-04 b_char_fast b_char_double b_risk b_brand_Novum -5.567e-05 -2.982e-05 5.124e-08 b_brand_BestValue -2.408e-05 1.8279e-04 -2.730e-07 b_brand_Supermarket 6.458e-05 2.9726e-04 -4.403e-07 b_brand_PainAway -1.0369e-04 4.283e-05 3.460e-08 b_country_CH 1.1822e-04 1.0981e-04 -1.619e-07 b_country_DK 5.871e-05 2.142e-05 -6.583e-08 b_country_IND -9.460e-05 -1.2918e-04 2.012e-07 b_country_RUS -1.8633e-04 -2.1139e-04 3.905e-07 b_country_BRA -1.5093e-04 -2.0051e-04 2.407e-07 b_char_fast 5.1012e-04 3.2273e-04 -2.188e-07 b_char_double 3.2273e-04 9.0793e-04 -2.109e-07 b_risk -2.188e-07 -2.109e-07 1.818e-09 b_price -9.871e-05 -1.1019e-04 1.941e-07 scale_2 -1.5110e-04 -1.8663e-04 4.098e-07 scale_3 -1.0196e-04 -6.865e-05 3.034e-07 b_price scale_2 scale_3 b_brand_Novum 4.015e-05 5.029e-05 3.783e-05 b_brand_BestValue 1.6914e-04 -1.754e-05 -1.617e-05 b_brand_Supermarket 1.2864e-04 -1.3613e-04 -4.823e-05 b_brand_PainAway 2.5632e-04 1.4779e-04 9.148e-05 b_country_CH -9.148e-05 -1.2373e-04 -6.625e-05 b_country_DK -3.682e-05 -5.683e-05 -5.965e-05 b_country_IND 6.887e-05 1.2427e-04 5.879e-05 b_country_RUS 1.4061e-04 2.2114e-04 1.4891e-04 b_country_BRA 1.1575e-04 1.6614e-04 1.0220e-04 b_char_fast -9.871e-05 -1.5110e-04 -1.0196e-04 b_char_double -1.1019e-04 -1.8663e-04 -6.865e-05 b_risk 1.941e-07 4.098e-07 3.034e-07 b_price 2.0654e-04 1.2117e-04 6.722e-05 scale_2 1.2117e-04 3.9624e-04 1.0721e-04 scale_3 6.722e-05 1.0721e-04 3.3571e-04 Classical correlation matrix: b_brand_Novum b_brand_BestValue b_brand_Supermarket b_brand_Novum 1.000000 0.281222 0.30919 b_brand_BestValue 0.281222 1.000000 0.72057 b_brand_Supermarket 0.309189 0.720571 1.00000 b_brand_PainAway 0.290641 0.676533 0.65919 b_country_CH -0.066604 0.293720 0.30909 b_country_DK -0.055656 0.293596 0.31276 b_country_IND -0.024471 -0.423719 -0.42982 b_country_RUS -0.008516 -0.383835 -0.40751 b_country_BRA 0.002949 -0.373434 -0.43660 b_char_fast -0.016056 -0.007261 0.05594 b_char_double 0.042768 0.165239 0.21502 b_risk 0.035586 -0.136759 -0.19498 b_price 0.087396 0.304516 0.24314 scale_2 0.054547 0.047849 -0.03372 scale_3 0.004358 -0.026771 -0.07763 b_brand_PainAway b_country_CH b_country_DK b_brand_Novum 0.29064 -0.06660 -0.05566 b_brand_BestValue 0.67653 0.29372 0.29360 b_brand_Supermarket 0.65919 0.30909 0.31276 b_brand_PainAway 1.00000 0.21940 0.25375 b_country_CH 0.21940 1.00000 0.48846 b_country_DK 0.25375 0.48846 1.00000 b_country_IND -0.36399 -0.04033 0.01430 b_country_RUS -0.28982 -0.06966 -0.02479 b_country_BRA -0.32919 -0.08840 -0.04412 b_char_fast -0.11331 0.13762 0.08593 b_char_double 0.06584 0.12514 0.04869 b_risk 0.05413 -0.13756 -0.07323 b_price 0.41094 -0.18897 -0.07569 scale_2 0.22838 -0.15278 -0.08344 scale_3 0.11522 -0.10129 -0.05782 b_country_IND b_country_RUS b_country_BRA b_brand_Novum -0.02447 -0.008516 0.002949 b_brand_BestValue -0.42372 -0.383835 -0.373434 b_brand_Supermarket -0.42982 -0.407507 -0.436596 b_brand_PainAway -0.36399 -0.289822 -0.329193 b_country_CH -0.04033 -0.069658 -0.088399 b_country_DK 0.01430 -0.024795 -0.044122 b_country_IND 1.00000 0.484932 0.503263 b_country_RUS 0.48493 1.000000 0.491175 b_country_BRA 0.50326 0.491175 1.000000 b_char_fast -0.09184 -0.152750 -0.119006 b_char_double -0.06455 -0.120841 -0.106997 b_risk 0.07557 0.190341 0.106953 b_price 0.07656 0.168499 0.158858 scale_2 0.07163 0.228299 0.150649 scale_3 0.09375 0.189126 0.129819 b_char_fast b_char_double b_risk b_brand_Novum -0.016056 0.04277 0.03559 b_brand_BestValue -0.007261 0.16524 -0.13676 b_brand_Supermarket 0.055941 0.21502 -0.19498 b_brand_PainAway -0.113309 0.06584 0.05413 b_country_CH 0.137617 0.12514 -0.13756 b_country_DK 0.085935 0.04869 -0.07323 b_country_IND -0.091836 -0.06455 0.07557 b_country_RUS -0.152750 -0.12084 0.19034 b_country_BRA -0.119006 -0.10700 0.10695 b_char_fast 1.000000 0.46599 -0.23848 b_char_double 0.465989 1.00000 -0.20859 b_risk -0.238480 -0.20859 1.00000 b_price -0.280245 -0.26365 0.33906 scale_2 -0.305547 -0.28627 0.46287 scale_3 -0.199746 -0.16441 0.38618 b_price scale_2 scale_3 b_brand_Novum 0.08740 0.05455 0.004358 b_brand_BestValue 0.30452 0.04785 -0.026771 b_brand_Supermarket 0.24314 -0.03372 -0.077632 b_brand_PainAway 0.41094 0.22838 0.115219 b_country_CH -0.18897 -0.15278 -0.101294 b_country_DK -0.07569 -0.08344 -0.057815 b_country_IND 0.07656 0.07163 0.093752 b_country_RUS 0.16850 0.22830 0.189126 b_country_BRA 0.15886 0.15065 0.129819 b_char_fast -0.28025 -0.30555 -0.199746 b_char_double -0.26365 -0.28627 -0.164412 b_risk 0.33906 0.46287 0.386183 b_price 1.00000 0.41057 0.233427 scale_2 0.41057 1.00000 0.277326 scale_3 0.23343 0.27733 1.000000 Robust correlation matrix: b_brand_Novum b_brand_BestValue b_brand_Supermarket b_brand_Novum 1.00000 0.20346 0.23449 b_brand_BestValue 0.20346 1.00000 0.73642 b_brand_Supermarket 0.23449 0.73642 1.00000 b_brand_PainAway 0.23530 0.71022 0.69017 b_country_CH -0.13846 0.22656 0.23535 b_country_DK -0.06652 0.20379 0.23614 b_country_IND 0.02989 -0.38604 -0.38756 b_country_RUS 0.04034 -0.35827 -0.38263 b_country_BRA 0.06850 -0.35586 -0.40690 b_char_fast -0.09987 -0.02225 0.05464 b_char_double -0.04010 0.12660 0.18855 b_risk 0.04869 -0.13361 -0.19736 b_price 0.11320 0.24560 0.17107 scale_2 0.10237 -0.01839 -0.13070 scale_3 0.08366 -0.01842 -0.05030 b_brand_PainAway b_country_CH b_country_DK b_brand_Novum 0.23530 -0.13846 -0.06652 b_brand_BestValue 0.71022 0.22656 0.20379 b_brand_Supermarket 0.69017 0.23535 0.23614 b_brand_PainAway 1.00000 0.17631 0.20692 b_country_CH 0.17631 1.00000 0.47309 b_country_DK 0.20692 0.47309 1.00000 b_country_IND -0.30676 -0.03440 0.01637 b_country_RUS -0.27610 -0.10014 -0.01480 b_country_BRA -0.28761 -0.07270 -0.04268 b_char_fast -0.09043 0.16596 0.08541 b_char_double 0.02800 0.11555 0.02336 b_risk 0.01599 -0.12037 -0.05073 b_price 0.35131 -0.20182 -0.08419 scale_2 0.14624 -0.19708 -0.09382 scale_3 0.09835 -0.11464 -0.10697 b_country_IND b_country_RUS b_country_BRA b_brand_Novum 0.02989 0.04034 0.06850 b_brand_BestValue -0.38604 -0.35827 -0.35586 b_brand_Supermarket -0.38756 -0.38263 -0.40690 b_brand_PainAway -0.30676 -0.27610 -0.28761 b_country_CH -0.03440 -0.10014 -0.07270 b_country_DK 0.01637 -0.01480 -0.04268 b_country_IND 1.00000 0.46384 0.52266 b_country_RUS 0.46384 1.00000 0.52134 b_country_BRA 0.52266 0.52134 1.00000 b_char_fast -0.09986 -0.19289 -0.15497 b_char_double -0.10221 -0.16403 -0.15431 b_risk 0.11248 0.21411 0.13090 b_price 0.11425 0.22875 0.18677 scale_2 0.14884 0.25975 0.19355 scale_3 0.07650 0.19002 0.12935 b_char_fast b_char_double b_risk b_brand_Novum -0.09987 -0.04010 0.04869 b_brand_BestValue -0.02225 0.12660 -0.13361 b_brand_Supermarket 0.05464 0.18855 -0.19736 b_brand_PainAway -0.09043 0.02800 0.01599 b_country_CH 0.16596 0.11555 -0.12037 b_country_DK 0.08541 0.02336 -0.05073 b_country_IND -0.09986 -0.10221 0.11248 b_country_RUS -0.19289 -0.16403 0.21411 b_country_BRA -0.15497 -0.15431 0.13090 b_char_fast 1.00000 0.47421 -0.22719 b_char_double 0.47421 1.00000 -0.16418 b_risk -0.22719 -0.16418 1.00000 b_price -0.30410 -0.25446 0.31681 scale_2 -0.33607 -0.31115 0.48286 scale_3 -0.24638 -0.12434 0.38837 b_price scale_2 scale_3 b_brand_Novum 0.11320 0.10237 0.08366 b_brand_BestValue 0.24560 -0.01839 -0.01842 b_brand_Supermarket 0.17107 -0.13070 -0.05030 b_brand_PainAway 0.35131 0.14624 0.09835 b_country_CH -0.20182 -0.19708 -0.11464 b_country_DK -0.08419 -0.09382 -0.10697 b_country_IND 0.11425 0.14884 0.07650 b_country_RUS 0.22875 0.25975 0.19002 b_country_BRA 0.18677 0.19355 0.12935 b_char_fast -0.30410 -0.33607 -0.24638 b_char_double -0.25446 -0.31115 -0.12434 b_risk 0.31681 0.48286 0.38837 b_price 1.00000 0.42357 0.25529 scale_2 0.42357 1.00000 0.29394 scale_3 0.25529 0.29394 1.00000 20 most extreme outliers in terms of lowest average per choice prediction: ID Avg prob per choice 875 0.01871662 367 0.02301821 859 0.02474799 593 0.02482774 678 0.02796633 1000 0.02836724 70 0.02958425 933 0.02988567 947 0.03009578 524 0.03026856 565 0.03048177 472 0.03059205 832 0.03062665 969 0.03108968 240 0.03131156 8 0.03162662 705 0.03182871 605 0.03232625 144 0.03275949 288 0.03282666 Settings and functions used in model definition: apollo_control -------------- Value modelDescr "Exploded logit model on drug choice data" indivID "ID" outputDirectory "output/" debug "FALSE" modelName "EL" nCores "1" workInLogs "FALSE" seed "13" mixing "FALSE" HB "FALSE" noValidation "FALSE" noDiagnostics "FALSE" calculateLLC "TRUE" analyticHessian "FALSE" memorySaver "FALSE" panelData "TRUE" analyticGrad "TRUE" analyticGrad_manualSet "FALSE" overridePanel "FALSE" preventOverridePanel "FALSE" noModification "FALSE" Hessian routines attempted -------------------------- numerical second derivative of LL (using numDeriv) Scaling used in computing Hessian --------------------------------- Value b_brand_Novum 0.285159056 b_brand_BestValue 0.562462145 b_brand_Supermarket 0.285310823 b_brand_PainAway 1.158670747 b_country_CH 0.585684613 b_country_DK 0.283668920 b_country_IND 0.279737783 b_country_RUS 0.851886048 b_country_BRA 0.612791420 b_char_fast 0.708283630 b_char_double 1.120312893 b_risk 0.001533091 b_price 0.703403028 scale_2 0.760857633 scale_3 0.455239363 apollo_probabilities ---------------------- function(apollo_beta, apollo_inputs, functionality="estimate"){ ### Attach inputs and detach after function exit apollo_attach(apollo_beta, apollo_inputs) on.exit(apollo_detach(apollo_beta, apollo_inputs)) ### Create list of probabilities P P = list() ### List of utilities: these must use the same names as in el_settings, order is irrelevant V = list() V[["alt1"]] = ( b_brand_Artemis*(brand_1=="Artemis") + b_brand_Novum*(brand_1=="Novum") + b_country_CH*(country_1=="Switzerland") + b_country_DK*(country_1=="Denmark") + b_country_USA*(country_1=="USA") + b_char_standard*(char_1=="standard") + b_char_fast*(char_1=="fast acting") + b_char_double*(char_1=="double strength") + b_risk*side_effects_1 + b_price*price_1) V[["alt2"]] = ( b_brand_Artemis*(brand_2=="Artemis") + b_brand_Novum*(brand_2=="Novum") + b_country_CH*(country_2=="Switzerland") + b_country_DK*(country_2=="Denmark") + b_country_USA*(country_2=="USA") + b_char_standard*(char_2=="standard") + b_char_fast*(char_2=="fast acting") + b_char_double*(char_2=="double strength") + b_risk*side_effects_2 + b_price*price_2) V[["alt3"]] = ( b_brand_BestValue*(brand_3=="BestValue") + b_brand_Supermarket*(brand_3=="Supermarket") + b_brand_PainAway*(brand_3=="PainAway") + b_country_USA*(country_3=="USA") + b_country_IND*(country_3=="India") + b_country_RUS*(country_3=="Russia") + b_country_BRA*(country_3=="Brazil") + b_char_standard*(char_3=="standard") + b_char_fast*(char_3=="fast acting") + b_risk*side_effects_3 + b_price*price_3 ) V[["alt4"]] = ( b_brand_BestValue*(brand_4=="BestValue") + b_brand_Supermarket*(brand_4=="Supermarket") + b_brand_PainAway*(brand_4=="PainAway") + b_country_USA*(country_4=="USA") + b_country_IND*(country_4=="India") + b_country_RUS*(country_4=="Russia") + b_country_BRA*(country_4=="Brazil") + b_char_standard*(char_4=="standard") + b_char_fast*(char_4=="fast acting") + b_risk*side_effects_4 + b_price*price_4 ) ### Define settings for exploded logit el_settings = list( alternatives = c(alt1=1, alt2=2, alt3=3, alt4=4), avail = list(alt1=1, alt2=1, alt3=1, alt4=1), choiceVars = list(best, second_pref, third_pref), utilities = V, scales = list(scale_1,scale_2,scale_3) ) ### Compute exploded logit probabilities P[["model"]]=apollo_el(el_settings, functionality) ### Take product across observation for same individual P = apollo_panelProd(P, apollo_inputs, functionality) ### Prepare and return outputs of function P = apollo_prepareProb(P, apollo_inputs, functionality) return(P) }