#A (set of) comparison(s) between the max R2 method and the elbow methods
#A new heatmap or two, based on a different location.
====New Do File====
There's a new do file, dataset and log file in the dropbox. The do file is reorganized and condensed into a single file. In order to select layers for specific purposes, like regressions, the do file uses flags (defined on lines 165-190). Do not try to run regressions using xt commands even with these flags, as the underlying layers used will be incorrect. Instead, put in the fixed effects yourself (using i.var) and put them at the front of the regression. STATA decides which variables to omit before doing the linear algebra, so you'll be able to get non-zero coefficients on omitted variables if you put them ahead of the fixed effects that would wipe them out.
The actual regressions I chose are on lines 243-250. There have the log of next period growth VC per startup as the dependent variable. Each spec uses year and city fixed effects, and clusters the standard errors at the city level. However, only the second spec in each sequence uses explicit scale controls.
'''Here's extracts of the results for Max R2:'''
reg growthinv18lfperstartup i.year i.placeid nohull tothullcountl tothullareal tothulldensityl avghulldisthml if regmaxr2==1, cluster(placeid)
nohull | 0 (omitted)
tothullcountl | -.0731116 .0170361 -4.29 0.000 -.1067484 -.0394748
tothullareal | .0166992 .0032354 5.16 0.000 .0103111 .0230873
tothulldensityl | -.0026603 .0034181 -0.78 0.438 -.0094092 .0040885
avghulldisthml | .0025771 .0060088 0.43 0.669 -.0092869 .0144411
reg growthinv18lfperstartup i.year i.placeid nohull tothullcountl tothullareal tothulldensityl avghulldisthml growthinv18l numstartupsl numdealsl if regmaxr2==1, cluster(placeid)
nohull | .0045458 .0007755 5.86 0.000 .0030165 .0060752
tothullcountl | .0042399 .0087493 0.48 0.629 -.0130145 .0214943
tothullareal | .0045121 .0042544 1.06 0.290 -.0038778 .0129021
tothulldensityl | .0163778 .0048519 3.38 0.001 .0068095 .0259462
avghulldisthml | -.0024717 .0026637 -0.93 0.355 -.0077247 .0027813
growthinv18l | .0075835 .0025118 3.02 0.003 .0026301 .012537
numstartupsl | -.1492758 .016447 -9.08 0.000 -.1817106 -.1168411
numdealsl | .0121621 .005014 2.43 0.016 .002274 .0220501
'''Here's extracts of the results for the 1st Heuristic (Percentage of startups in clusters):'''
reg growthinv18lfperstartup i.year i.placeid nohull tothullcountl tothullareal tothulldensityl avghulldisthml if regheur1==1, cluster(placeid)
nohull | .0029949 .0007993 3.75 0.000 .0014186 .0045713
tothullcountl | -.0555213 .0124065 -4.48 0.000 -.0799879 -.0310547
tothullareal | .0194877 .0041551 4.69 0.000 .0112936 .0276819
tothulldensityl | .0083321 .0049398 1.69 0.093 -.0014096 .0180737
avghulldisthml | .001081 .0027112 0.40 0.691 -.0042658 .0064277
reg growthinv18lfperstartup i.year i.placeid nohull tothullcountl tothullareal tothulldensityl avghulldisthml growthinv18l numstartupsl numdealsl if regheur1==1, cluster(placeid)
nohull | .0045458 .0007755 5.86 0.000 .0030165 .0060752
tothullcountl | .0042399 .0087493 0.48 0.629 -.0130145 .0214943
tothullareal | .0045121 .0042544 1.06 0.290 -.0038778 .0129021
tothulldensityl | .0163778 .0048519 3.38 0.001 .0068095 .0259462
avghulldisthml | -.0024717 .0026637 -0.93 0.355 -.0077247 .0027813
growthinv18l | .0075835 .0025118 3.02 0.003 .0026301 .012537
numstartupsl | -.1492758 .016447 -9.08 0.000 -.1817106 -.1168411
numdealsl | .0121621 .005014 2.43 0.016 .002274 .0220501
Lines 252 to 255 of the do file also compare the lense given by the max r2 method and the 1st heuristic method. The results are below. Note that the second spec shows the 1st heuristic for all city-years and the third spec shows it for the city-years that have a max R2 layer, to make a fairer comparison.
. tabstat nohull tothullcount tothullarea tothulldensity growthinv18 numdeals numstartups if '''regmaxr2==1''', stats(p50 mean sd N min max p10 p90) columns(statistics)
variable | p50 mean sd N min max p10 p90
-------------+--------------------------------------------------------------------------------
nohull | 2 3.862758 7.279538 2951 1 67 1 7
tothullcount | 8 19.18841 36.62401 2951 3 369 3 37
tothullarea | 15.2049 431.5689 2067.431 2951 4.04e-06 34780.04 .7658609 606.8908
tothullden~y | .8115587 258.0355 13679.93 2951 .0002282 743141.7 .0123656 12.06713
growthinv18 | 33.16967 141.5326 563.4799 2951 0 22282.6 1.412436 298.6927
numdeals | 3 6.630973 17.17611 2951 0 275 0 14
numstartups | 16 41.2528 90.67289 2951 6 1317 7 87
----------------------------------------------------------------------------------------------
. tabstat nohull tothullcount tothullarea tothulldensity growthinv18 numdeals numstartups if '''regheur1==1''', stats(p50 mean sd N min max p10 p90) columns(statistics)
variable | p50 mean sd N min max p10 p90
-------------+--------------------------------------------------------------------------------
nohull | 2 4.519621 8.1655 3797 0 109 1 9
tothullcount | 11 22.48512 40.38281 3797 0 572 6 44
tothullarea | 42.05454 311.2049 1020.574 3797 0 14343.08 4.035411 677.4176
tothullden~y | .3111306 4.461828 28.35013 3797 0 813.2376 .0116532 5.873065
growthinv18 | 31.8453 133.0608 508.1196 3797 0 22282.6 1.235763 292.4397
numdeals | 2 6.629181 16.46614 3797 0 275 0 15
numstartups | 15 38.74743 83.6814 3797 6 1317 7 83
----------------------------------------------------------------------------------------------
. tabstat nohull tothullcount tothullarea tothulldensity growthinv18 numdeals numstartups if '''regheur1==1 & compok==1''' , stats(p50 mean sd N min max p10 p90) columns(statistics)
variable | p50 mean sd N min max p10 p90
-------------+--------------------------------------------------------------------------------
nohull | 2 4.753304 8.607258 2951 0 109 1 9
tothullcount | 11 23.58353 42.91556 2951 0 572 6 43
tothullarea | 43.43438 318.6861 1075.779 2951 0 14343.08 4.259536 664.985
tothullden~y | .3187791 5.188776 31.84423 2951 0 813.2376 .0138936 6.80843
growthinv18 | 33.16967 141.5326 563.4799 2951 0 22282.6 1.412436 298.6927
numdeals | 3 6.630973 17.17611 2951 0 275 0 14
numstartups | 16 41.2528 90.67289 2951 6 1317 7 87
----------------------------------------------------------------------------------------------
===A list of items===