Hello there,
I would like to get some assistance please, on how to visually depict the interactive effect in my survival analysis. This is a pretty long one, so kindly bear with me
For example, an estimation of the likelihood of a potential target firm being acquired, contingent on external factors such as industry competition (continuous variable) and level of industry sales (continuous variable) as well as internal factors of potential target firms such as assets (continuous variable) and number of employees (continuous variable), and also some interaction variables such as competition*assets and competition*#employees.
The analysis will involve streg (Parametric survival model):
stset LFE_REFYR, failure(acquired) id(OP_ID)
streg compet partner assets employ compet_assets compet_employ, dist(e) nohr
where 'acquired' is a dichotomous categorical variable indicating if the potential target firm is acquired (1 = acquired; 0 = not acquired)
LFE_REFYR = year
OP_ID is the target firm's unique ID
compet = industry competition
indsales = level of industry sales
assets = assets of potential target firms
employ = number of employees of potential target firms
compet_assets = interaction variable between industry competition and assets
compet_employ = interaction variable between industry competition and number of employees
The plot of the interactive effect will show how the effect of competition on likelihood of acquisition changes with the level of potential target firm assets:
y-axis: probability of being acquired
x-axis: industry competition represented in standard deviation units [mean +/- standard deviation units in 0.5 unit increments]
The plot will show two curves - one for high-asset target firms and the other for low-asset target firms; high-asset target firms are those whose assets are more than the top quartile, while low-asset target firms are those whose assets are less than the top quartile; all other variables will be held at their mean levels.
Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input float(LFE_REFYR OP_ID compet indsales) double assets int employ byte acquired float(compet_assets compet_employ)
2000 12341 .462056 29802180 135560.76120556414 11 0 62636.66 5.082616
2000 12342 .3484394 50860816 289909.5652173914 13 0 101015.9 4.5297117
2000 12343 .2283101 50080384 225511.36363636362 10 0 51486.52 2.283101
2000 12344 .3229231 71408080 1019090.2366863905 15 0 329087.8 4.843847
2000 12345 .40260035 17703958 873875.2642706131 8 0 351822.5 3.220803
2000 12346 .50641453 5886413 638726.6355140187 15 0 323460.4 7.596218
2000 12347 .6789437 11288420 2207725.587144623 7 0 1498921.4 4.752606
2000 12348 .8942683 6824116 93530.0586510264 12 0 83640.96 10.73122
end
Can you kindly help?
Thanks!