Select Page

This is the first in what will be a series of articles exploring how to use quantitative and machine learning methods to construct portfolios. By construction, we mean some combination of selecting assets and determining weights.

We describe a method of taking a fixed portfolio and generating a range of possible weights to use as a guide in setting actual weights for the portfolio. Here are the steps:

1. Choose a portfolio – We use the 2023 Dogs Of The Dow portfolio.
2. Set the following parameters – trade direction (long or long/short), use cash (if yes, we use the T-bill ETF BIL).
3. Generate 100,000 sets of random weights, using uniform random weights that are then normalized.
4. Simulate for 21, 63, 126, 189, and 252 days before the current day and decide if rebalancing should be used. In this example we rebalance at the end of each quarter if the number of simulation days are greater than 63.
5. Each simulation creates a time series. For each time series, record various performance measures. Here we compute: total return, maximum drawdown, and pseudo mar (total return/maximum drawdown).
6. Apply K-Means to the weights with N clusters. In this example we set N=15. Select the N weights that are closest to their respective centroids.

K-Means is technically a data partition algorithm, rather than a cluster algorithm. As such, it takes the 100,000 sets of weights and reduces them to 15 sets that are distributed in the data space of the random weights. Note that there is no optimization here. Our goal is to generate a set of weights that have had various outcomes over the last given number of formation days.

Using various formation days is important as the assets in a portfolio can display various behaviors over various time periods. Some mean revert, some trend, some are range bound, etc. Thus we could use known market conditions over the last number of formation days and combine this with even vague opinions about future conditions to examine weights that resulted in gains, losses, or were relatively flat.

Results:

Name
VZVerizon Communications
DOWDow
INTCIntel
WBAWalgreens Boots Alliance
MMM3M
AMGNAmgen
CSCOCisco Systems
CVXChevron
JPMJPMorgan Chase & Co.

Formation DaysVZDOWINTCWBAMMMIBMAMGNCSCOCVXJPMtotal_returnmaximum_drawdownpseudo_mar
210.14760.12040.130.13120.0750.07020.07620.05650.14330.04955.00222.35872.1207
210.07060.08170.14650.09140.10450.05180.14780.1490.08650.07036.11212.20552.7713
210.07730.13710.11020.05370.13710.06270.08150.09660.13240.11146.49432.21232.9355
210.14340.12080.06790.10150.1510.08480.12570.0730.08120.05075.69662.0612.764
210.06630.10690.14240.10350.15090.13070.0520.10470.07250.076.63632.1823.0414
210.11960.07190.10240.04370.12530.13740.07210.12410.11730.08636.10542.08932.9223
210.06260.05560.11090.11220.08160.12630.06290.08930.14660.1527.02461.9333.6341
210.07040.16410.04610.0690.0840.11870.12090.12510.15980.04185.78391.81143.1931
210.13570.07550.08640.0650.0920.04290.13640.09680.13320.13615.97432.02642.9482
210.12270.07580.08970.13940.0520.13990.16260.10910.04080.0685.6121.81493.0922
210.13180.1480.13970.07390.0340.14630.04580.09370.04550.14155.6831.87033.0385
210.04570.12740.12710.15390.07160.05930.1540.04770.09410.11916.5361.96743.3221
210.09010.08360.07050.07580.13330.13490.12540.06320.08010.1436.97331.97333.5338
210.07110.04640.1030.13490.13990.07780.13320.11110.14270.03996.36552.09683.0358
210.13540.09380.07790.12550.12320.06180.04230.13030.06750.14236.54211.7743.6877
630.05460.09710.12180.0820.06620.0570.14490.09660.14030.13955.67826.39010.8886
630.06940.0820.04110.07140.12880.14440.12140.1240.09620.12156.31075.0671.2455
630.13660.14420.080.06960.07850.11560.11620.09310.05980.10645.36276.05120.8862
630.07240.06380.10690.11780.14370.0650.0760.13050.14440.07955.45026.40790.8505
630.0990.1190.05430.14160.12920.07340.15720.08860.08830.04943.1787.05260.4506
630.14440.14980.1320.12020.04370.08450.07570.08350.10450.06164.13577.20340.5741
630.13430.05870.06320.1360.04610.08140.14420.12370.11230.10023.55866.41950.5543
630.09810.12050.10460.07580.09760.07860.06280.15510.05280.1547.36195.40691.3616
630.11870.06440.14350.07520.14270.0610.1430.12910.04240.086.36236.55030.9713
630.14390.08070.12610.05730.05470.14560.08120.07960.12580.10515.91296.04840.9776
630.13270.05160.0580.11960.16580.09170.07370.08850.06850.14995.46116.22940.8767
630.140.14550.0640.04390.1270.08360.04670.09730.15680.09525.06116.05870.8353
630.0650.11510.14980.07160.15920.14690.050.0560.08230.1047.64666.21241.2309
630.07790.1190.05490.14180.07480.13750.09370.07510.15220.07313.73366.38420.5848
630.06740.06960.13450.1480.07760.13770.13190.06810.0640.10115.61036.68670.839
1260.13270.09860.13740.14660.11230.06370.05670.05830.05390.13980.950810.61430.0896
1260.06570.03860.07260.12970.13990.07450.13090.13320.06280.15211.75689.21980.1905
1260.06910.10490.13680.04810.10260.08580.13270.0680.13880.11321.21869.43820.1291
1260.04970.14430.13080.05470.09970.1120.0460.14420.08730.13133.50648.43110.4159
1260.13620.13350.0810.10620.08680.11810.08550.13040.04250.07970.064810.06970.0064
1260.10810.08510.1130.08880.05770.08730.0620.1330.14170.12341.42218.60220.1653
1260.10010.04610.10080.06230.14370.14280.06840.11760.11830.09981.76198.8770.1985
1260.13010.06880.06640.12440.07240.11030.13490.06490.13480.0932-1.722410.0921-0.1707
1260.13910.13360.16860.07010.06880.13630.0820.07090.08880.04170.299510.05470.0298
1260.06540.13620.0520.08360.04590.1280.13720.13410.13240.0853-0.40389.0673-0.0445
1260.07410.10630.15160.14040.09080.12430.11040.07330.08260.04640.145510.36390.014
1260.13280.13880.06180.05330.12740.09150.12830.06740.04690.15170.2710.14750.0266
1260.05820.1540.10450.12990.11820.07160.10.07560.11590.0719-0.577710.7615-0.0537
1260.04630.10740.08940.13650.05340.14070.08690.0740.12660.13890.70929.10780.0779
1260.1340.07560.15850.04870.09170.08570.16110.12820.05460.0621.37239.32210.1472
1890.04760.12250.13590.05060.07930.14890.06610.14240.07150.135215.305710.10591.5145
1890.0380.09360.1440.07290.12980.08560.09910.0850.1310.12111.791511.46021.0289
1890.13980.1360.06720.14010.09430.09880.04250.06520.0750.140910.4112.08450.8614
1890.14030.06730.0760.14840.14750.04590.11310.04830.13550.07765.947113.98880.4251
1890.1160.05580.13660.11660.14410.15040.05490.08310.07510.067310.421112.14750.8579
1890.05770.0750.09740.12960.04260.14130.12650.05190.13010.14810.085511.88780.8484
1890.15580.06570.11750.07970.05530.10530.12220.08940.12710.08199.586511.59230.827
1890.07250.10260.14590.14770.0570.0680.05310.12690.1570.069310.919910.82111.0091
1890.13550.04280.09610.0970.07610.15390.13620.14710.06240.05299.780911.66670.8384
1890.09360.12920.06220.06120.0740.02870.13730.15810.15090.10510.050811.16490.9002
1890.0760.1290.07960.10350.11980.12220.06910.08860.14780.06448.898512.28180.7245
1890.13980.12990.12740.07320.14060.05770.06630.13840.06030.066411.7511.78680.9969
1890.06620.13910.12320.12770.11730.07160.15290.06640.06390.07179.218312.94920.7119
1890.11040.09490.07290.06760.1160.09570.14580.06870.07760.150510.120312.34050.8201
1890.08220.06390.09980.13480.12260.09610.06580.14690.04410.143812.580210.90161.154
2520.05080.05210.12440.09860.1370.14360.09190.13950.0860.0764.367617.98870.2428
2520.15830.15890.07020.06450.07280.07510.14360.0680.12680.06172.012816.76560.1201
2520.05120.04460.06230.11320.14080.05820.15550.12760.14630.10044.066316.79680.2421
2520.06540.06520.12340.13640.08730.1330.1350.05640.12920.06872.632517.45950.1508
2520.12080.12710.0440.12870.1340.0760.06060.13950.06880.10053.068118.22850.1683
2520.14310.15370.13940.11250.03460.14250.0540.08040.04770.0923.702518.50620.2001
2520.060.12540.13350.09470.14310.06430.08580.06140.11450.11743.508318.62320.1884
2520.05870.09880.04140.16160.05120.09580.06240.12210.13170.17628.706716.85510.5166
2520.13930.07480.12130.10380.09310.03610.06390.1490.14070.0782.900817.79130.163
2520.1290.08270.05930.08890.07510.11990.13380.13650.05780.11685.189916.84190.3082
2520.09120.12720.11360.07150.06480.08750.13850.11710.05240.13636.21817.53950.3545
2520.05510.15460.0650.07760.10730.15890.15810.04120.06680.11525.074617.19820.2951
2520.15190.05140.05580.06950.11420.13460.08320.06960.14450.12544.364316.47270.2649
2520.0550.14420.08540.05820.08330.16750.04440.1390.13640.08658.171417.16880.4759
2520.1430.06360.10750.11780.12050.07760.1330.05750.06950.11010.867218.18920.0477

The CSV files are available in the ZIP file: Dogs Of The Dow 2023 Results.

If you wish to see these results for well known portfolios each month, please let us know in the comments and provide a link to the requested portfolio.

If you find information presented in this article useful, we ask that you provide value in return via the Value 4 Value links on the homepage. We would also appreciate you spreading the word about our work.

We repeated this analysis with modifications of the steps listed above.
1. Vanguard stock sector ETFs
4. simulation was for 100 days, with rebalancing at the end of each quarter (last date was 20230811)
5. additional analytics: slope of the simulated time series, standard_deviation, and breakout shifted (last time series value – min value)/(max value – min value)

Also, we show results for the maximum and minimum values of each analysis type.

## Vanguard Stock Sectors ETFs

Name
VOXVanguard Communication Services ETF
VCRVanguard Consumer Discretionary ETF
VDCVanguard Consumer Staples ETF
VDEVanguard Energy ETF
VFHVanguard Financials ETF
VHTVanguard Health Care ETF
VISVanguard Industrials ETF
VGTVanguard Information Technology ETF
VAWVanguard Materials ETF
VNQVanguard Real Estate ETF
VPUVanguard Utilities ETF

## Maximum and Minimum Analytics

total_returnbreakout_shiftedslopemaximum_drawdownpseudo_marstandard_deviationVOXVCRVDCVDEVFHVHTVISVGTVAWVNQVPU
13.02510.88980.15523.08344.22424.68310.26460.20830.07170.07530.10230.01970.07590.0593-0.003-0.0138-0.1061
-12.12050.1287-0.14514.8279-0.81744.4729-0.1333-0.1592-0.0372-0.1585-0.0245-0.0114-0.1127-0.1685-0.1028-0.03530.0565
3.96861.00.02682.69591.47211.2369-0.06970.167-0.01350.1840.1789-0.00140.0439-0.1081-0.1577-0.038-0.0378
-3.62180.0-0.01583.252-1.11370.6382-0.0897-0.11850.014-0.09830.0649-0.1567-0.04860.10620.08110.13370.0883
12.23920.78470.17743.17173.85885.41620.09170.2572-0.0438-0.01380.0560.04990.18510.20340.06930.00960.0202
-10.8980.2008-0.1514.2464-0.7654.5565-0.1765-0.19940.0512-0.02760.0459-0.0122-0.0736-0.271-0.04730.0459-0.0494
5.72121.00.05240.72017.9451.54040.04630.03910.12860.0904-0.09260.13330.11340.0929-0.1201-0.0349-0.1084
-2.35380.0-0.00461.8377-1.28090.4263-0.13980.0720.0079-0.08310.1004-0.11870.0862-0.0328-0.1460.1190.0941
12.23920.78470.17743.17173.85885.41620.09170.2572-0.0438-0.01380.0560.04990.18510.20340.06930.00960.0202
-0.53140.0802-0.00080.9709-0.54740.21270.15130.00180.0819-0.08610.121-0.1419-0.0939-0.0870.0776-0.07820.0792
-11.31350.1876-0.148115.508-0.72954.5816-0.1688-0.12510.0039-0.0747-0.0388-0.0265-0.0958-0.1963-0.1665-0.0622-0.0416
2.27150.92040.0230.59353.82750.70940.091-0.12260.1315-0.0145-0.04740.09710.14050.058-0.1280.0687-0.1007

## K-Means Weights and Analytics

total_returnbreakout_shiftedslopemaximum_drawdownpseudo_marstandard_deviationVOXVCRVDCVDEVFHVHTVISVGTVAWVNQVPU
2.30230.640.03711.40641.63711.16070.1293-0.1243-0.042-0.0651-0.07690.10690.07310.09310.11850.0831-0.0878
-1.5010.0-0.00493.0755-0.48810.66330.0206-0.1260.0463-0.0477-0.0988-0.11890.12540.138-0.0583-0.1050.1151
-1.24170.0881-0.00174.8777-0.25461.20240.0863-0.0673-0.077-0.10320.0832-0.0353-0.12250.1199-0.1102-0.1047-0.0905
1.31760.91050.00773.90670.33731.0222-0.01530.02460.1060.1165-0.1022-0.13160.1129-0.07910.11550.09850.0978
0.25460.6339-0.00221.49830.170.294-0.09410.0578-0.09190.0939-0.08540.0875-0.08950.0797-0.11170.1291-0.0795
-0.54260.7349-0.02493.7-0.14660.9774-0.0715-0.1148-0.07590.09590.11270.07170.1354-0.0838-0.064-0.0666-0.1077
0.38170.3950.01722.3640.16150.77540.059-0.14330.1019-0.08840.1420.0684-0.06570.11320.03730.08350.0974
2.2850.58250.05892.65110.86191.922-0.07540.1172-0.0419-0.13680.0915-0.08680.08830.09740.1065-0.0712-0.087
1.11230.6340.03361.37790.80721.07740.13660.1034-0.0849-0.0920.1099-0.08910.0284-0.1187-0.04770.12020.069
3.01861.00.00512.07341.45590.62880.13970.08170.11410.1041-0.0650.0498-0.0997-0.1220.0804-0.0724-0.0711
9.48290.87230.10513.2492.91873.40970.05340.11180.07690.1160.11340.12270.12990.0620.0963-0.0550.0625
-2.18720.3258-0.03984.3344-0.50461.2799-0.12330.0540.07950.07020.1437-0.0611-0.1162-0.0598-0.0624-0.12840.1014
0.13190.50860.00592.09710.06290.62090.1072-0.0954-0.1430.07230.0269-0.0912-0.09020.04720.12320.06250.1408
-8.07410.1845-0.09710.9541-0.73713.0367-0.1026-0.0661-0.0355-0.0713-0.1287-0.0771-0.0631-0.1395-0.08850.1121-0.1154
-3.46930.1363-0.03734.1633-0.83331.1567-0.11090.0923-0.1117-0.088-0.07620.0880.0603-0.11970.0698-0.08580.0972