Paper Writing Services m found in 2). Discuss the impact of the number of samples to the accuracy of the returned parameters.[You need to plot

Abstract
an unknown polynomial using the polyfit() function of the numpy package. 1)Please plot the noisy data and the polynomial you found (in the same figure). You can use any value of m selected from 2, 3, 4, 5, 6. 2)Plot MSE versusorder m,for m = 1, 2, 3, 4, 5, 6, 7, 8respectively.Identify the best choice of m.

In ts problem, we write a program to estimate the parameters for an unknown polynomial using the polyfit() function of the numpy package. 1)Please plot the noisy data and the polynomial you found (in the same figure). You can use any value of m selected from 2, 3, 4, 5, 6. 2)Plot MSE versusorder m,for m = 1, 2, 3, 4, 5, 6, 7, 8respectively.Identify the best choice of m. 3)Change variable noise_scaleto 150, 200, 400, 600, 1000 respectively,re-run the algorithm and plot the polynomialswith the m found in 2). Discuss the impact of noise scale to the accuracy of the returned parameters.[You need to plot a figure like in 1) for each choice of noise_scale.] 4)Change variable number_of_samplesto 40, 30, 20, 10 respectively, re-ran the algorithm and plot the polynomialswith the m found in 2). Discuss the impact of the number of samples to the accuracy of the returned parameters.[You need to plot a figure like in 1) for each choice of number_of_samples.]A simulateddataset will be providedas below.The polynomial used is y = 5 * x + 20 * x2+ x3.Simulated data is given as follows in Python:import matplotlib.pyplot as pltplt.style.use(‘seaborn-wtegrid’)import numpy as npnoise_scale = 100number_of_samples = 50x =  25*(np.random.rand(number_of_samples, 1) -0.8)y = 5 * x + 20 * x**2 + 1 * x**3 + noise_scale*np.random.randn(number_of_samples, 1)plt.plot(x,y,’ro’)

Sample references
  • (‘Merriam Webster Dictionary. Competence. Merriam-webster.com Web site. https://www.merriam-webster.com/dictionary/competence. Accessed March 1, 2021.’,)
  • (‘Hay, S. I., J. Cox, D. J. Rogers, S. E. Randolph, D. I. Stern, G. D. Shanks, M. F. Myers, and R. W. Snow. 2002. Climate change and the resurgence of malaria in the East African highlands. Nature 415(6874):905-909.’,)
  • (‘Levine, Ross. 2005. Finance and Growth: Theory and Evidence. In Handbook of Economic Growth. Edited by Philippe Aghion and StevenDurlauf. Amsterdam: Elsevier, pp. 866–934.’,)
  • (‘Aiken, L. H., Sloane, D. M., Bruyneel, L., Van den Heede, K., Griffiths, P., Busse, R., …Lesaffre, E. (2014). Nurse staffing and education and hospital mortality in nineEuropean countries: A retrospective observational study. The Lancet, 383(9931),1824-1830.’,)

Need your ASSIGNMENT done? Use our paper writing service to score better and meet your deadline.


Click Here to Make an Order Click Here to Hire a Writer