Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

4. Te get an idea hnw lters can reduce noise? apply a ten-peint moving average lter to the data [see 4.9.21]. You can de this

4. Te get an idea hnw lters can reduce noise? apply a ten-peint moving average lter to the data [see 4.9.21]. You can de this manually by shifting, but Matlab has built-in capability. Try the filter enmmand: fer syntax? eee help filter. Plet bath the raw data and the ltered data. 1What's the di'erenee between them? 5. Cletna' strategy is the eaait to calculate. Haw much meney does he have in his back yard nn December 1. 201$? . Eeb'a strategr is the next easiest to track. How many shares d he have at the end of the data set? Hem mueh meney would he get if he sold them all for the December El pride"? 3 Normal Mode This mode involv monthly data about the closing price of the 5&1? 500 stock index on the rst day of trading every month from January, Qll through December. 201E. 1We're going to try to predict the stock marketl Let's see how that goes for us... Three investors are saving for retirement by putting $50!] every month into a fund that performs identically to the 5.841? El] {if the stock price is $lyllll]? let's say they can buy half a share that month; if the stock price is $T5ll. they can buy 2H of a share1 and so on). For this mode? we're ignoring ination They each pursue different strategim: i Aggressive Alice trim to use a moving average to gure out the best timm to buy and sell. I Boring Bob uses a \"buy and hold" strategy: he just buys his $501] worth of stock every month and doesn't look at whether it's going up or down. I Crafty lCletus hidm $5013 every month in a tin can buried in his back yard. He doesn't buy any stock ever. 1. Alice's \"moving average" strategr is the most complicated. We'll run the numbers for it in hard mode. For now? consider the three-point moving average 31: = l:1I."3]l:;r,|yg + yk_1 + Hits] to be a linear transformation T : E > S, where E is the space of discrete signals. lClive a basis for the kernel of 1\". What signals does the 3-point moving average lter out? 2. import the data using the osvrea command to open the le sp500.osv, which is just a list of comma-separated variables. 3. Plot this data to get an overview of the uctuations in the market. Treat it as a signal, just as in section 4.3. qattachments_035ad1e0847c26816542d75739ed663d06b2efc1 Date SP500 1/3/2000 1455.22 2/1/2000 1409.28 3/1/2000 1379.19 4/3/2000 1505.97 5/1/2000 1468.25 6/1/2000 1448.81 7/3/2000 1469.32 8/1/2000 1438.1 9/1/2000 1520.77 10/2/2000 1436.23 11/1/2000 1421.22 12/1/2000 1315.23 1/2/2001 1283.27 2/1/2001 1373.47 3/1/2001 1241.23 4/2/2001 1145.87 5/1/2001 1266.44 6/1/2001 1260.67 7/2/2001 1236.72 8/1/2001 1215.93 9/4/2001 1132.94 10/1/2001 1038.55 11/1/2001 1084.1 12/3/2001 1129.9 1/2/2002 1154.67 2/1/2002 1122.2 3/1/2002 1131.78 4/1/2002 1146.54 5/1/2002 1086.46 6/3/2002 1040.68 7/1/2002 968.65 8/1/2002 884.66 9/3/2002 878.02 10/1/2002 847.91 11/1/2002 900.96 12/2/2002 934.53 1/2/2003 909.03 2/3/2003 860.32 3/3/2003 834.81 4/1/2003 858.48 5/1/2003 916.3 6/2/2003 967 7/1/2003 982.32 8/1/2003 980.15 9/2/2003 1021.99 10/1/2003 1018.22 11/3/2003 1059.02 12/1/2003 1070.12 1/2/2004 1108.48 2/2/2004 1135.26 3/1/2004 1155.97 4/1/2004 1132.17 Page 1 qattachments_035ad1e0847c26816542d75739ed663d06b2efc1 5/3/2004 6/1/2004 7/1/2004 8/2/2004 9/1/2004 10/1/2004 11/1/2004 12/1/2004 1/3/2005 2/1/2005 3/1/2005 4/1/2005 5/2/2005 6/1/2005 7/1/2005 8/1/2005 9/1/2005 10/3/2005 11/1/2005 12/1/2005 1/3/2006 2/1/2006 3/1/2006 4/3/2006 5/1/2006 6/1/2006 7/3/2006 8/1/2006 9/1/2006 10/2/2006 11/1/2006 12/1/2006 1/3/2007 2/1/2007 3/1/2007 4/2/2007 5/1/2007 6/1/2007 7/2/2007 8/1/2007 9/4/2007 10/1/2007 11/1/2007 12/3/2007 1/2/2008 2/1/2008 3/3/2008 4/1/2008 5/1/2008 6/2/2008 7/1/2008 8/1/2008 9/2/2008 1117.49 1121.2 1128.94 1106.62 1105.91 1131.5 1130.51 1191.37 1202.08 1189.41 1210.41 1172.92 1162.16 1202.27 1194.44 1235.35 1221.59 1226.7 1202.76 1264.67 1268.8 1282.46 1291.24 1297.81 1305.19 1285.71 1280.19 1270.92 1311.01 1331.32 1367.81 1396.71 1416.6 1445.94 1403.17 1424.55 1486.3 1536.34 1519.43 1465.81 1489.42 1547.04 1508.44 1472.42 1447.16 1395.42 1331.34 1370.18 1409.34 1385.67 1284.91 1260.31 1277.58 Page 2 qattachments_035ad1e0847c26816542d75739ed663d06b2efc1 10/1/2008 11/3/2008 12/1/2008 1/2/2009 2/2/2009 3/2/2009 4/1/2009 5/1/2009 6/1/2009 7/1/2009 8/3/2009 9/1/2009 10/1/2009 11/2/2009 12/1/2009 1/4/2010 2/1/2010 3/1/2010 4/1/2010 5/3/2010 6/1/2010 7/1/2010 8/2/2010 9/1/2010 10/1/2010 11/1/2010 12/1/2010 1/3/2011 2/1/2011 3/1/2011 4/1/2011 5/2/2011 6/1/2011 7/1/2011 8/1/2011 9/1/2011 10/3/2011 11/1/2011 12/1/2011 1/3/2012 2/1/2012 3/1/2012 4/2/2012 5/1/2012 6/1/2012 7/2/2012 8/1/2012 9/4/2012 10/1/2012 11/1/2012 12/3/2012 1/2/2013 2/1/2013 1161.06 966.3 816.21 931.8 825.44 700.82 811.08 877.52 942.87 923.33 1002.63 998.04 1029.85 1042.88 1108.86 1132.99 1089.19 1115.71 1178.1 1202.26 1070.71 1027.37 1125.86 1080.29 1146.24 1184.38 1206.07 1271.87 1307.59 1306.33 1332.41 1361.22 1314.55 1339.67 1286.94 1204.42 1099.23 1218.28 1244.58 1277.06 1324.09 1374.09 1419.04 1405.82 1278.04 1365.51 1375.14 1404.94 1444.49 1427.59 1409.46 1462.42 1513.17 Page 3 qattachments_035ad1e0847c26816542d75739ed663d06b2efc1 3/1/2013 4/1/2013 5/1/2013 6/3/2013 7/1/2013 8/1/2013 9/3/2013 10/1/2013 11/1/2013 12/2/2013 1/2/2014 2/3/2014 3/3/2014 4/1/2014 5/1/2014 6/2/2014 7/1/2014 8/1/2014 9/2/2014 10/1/2014 11/3/2014 12/1/2014 1/2/2015 2/2/2015 3/2/2015 4/1/2015 5/1/2015 6/1/2015 7/1/2015 8/3/2015 9/1/2015 10/1/2015 11/2/2015 12/1/2015 1/4/2016 2/1/2016 3/1/2016 4/1/2016 5/2/2016 6/1/2016 7/1/2016 8/1/2016 9/1/2016 10/3/2016 11/1/2016 12/1/2016 1518.2 1562.17 1582.7 1640.42 1614.96 1706.87 1639.77 1695 1761.64 1800.9 1831.98 1741.89 1845.73 1885.52 1883.68 1924.97 1973.32 1925.15 2002.28 1946.16 2017.81 2053.44 2058.2 2020.85 2117.39 2059.69 2108.29 2111.73 2077.42 2098.04 1913.85 1923.82 2104.05 2102.63 2012.66 1939.38 1978.35 2072.78 2081.43 2099.33 2102.95 2170.84 2170.86 2161.2 2111.72 2191.08 Page 4

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Statistical Inference

Authors: George Casella, Roger L. Berger

2nd edition

0534243126, 978-0534243128

More Books

Students also viewed these Mathematics questions

Question

=+What, if any, of these strategies were adopted in this project?

Answered: 1 week ago