Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Fitting a curve to your data in MATLAB can show trends and estimate values not included in the data set. n this problem, we will

image text in transcribed

Fitting a curve to your data in MATLAB can show trends and estimate values not included in the data set. n this problem, we will use MATLAB's built-in polynomial curve fitting functions to fit a curve to a sus's velocity data given in the Excel file 'Bus_Data.xlsx'. a) Read the Excel file 'Bus_Data.xlsx' into the Workspace and call the data set BusData (this must be done using a function in your m-file). b) BusData should be a 262 matrix. The first column is the time increment from 0 to 7.5. This should be saved as a separate variable called Time. The second column is the velocity of the bus in mph. This should be saved as a separate variable called Velocity. c) Plot the Velocity vs. Time using blue star markers with no line. d) Use polyfit and polyval functions to find the best-fit coefficients and fitted data points for the polynomial curve. Call the output of the polyfit function coeffs and the output of the polyval function y_fit. Test different order polynomials in the polyfit function to find the best fit curve for the data. e) Plot y_fit vs. Time as a red line on the same plot as the original data (from Part C). f) Title the plot 'Bus Velocity vs. Time'. Provide correct x-axis labels (including correct units). Include a legend to distinguish the real data points from the fitted curve

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

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2017 Skopje Macedonia September 18 22 2017 Proceedings Part 3 Lnai 10536

Authors: Yasemin Altun ,Kamalika Das ,Taneli Mielikainen ,Donato Malerba ,Jerzy Stefanowski ,Jesse Read ,Marinka Zitnik ,Michelangelo Ceci ,Saso Dzeroski

1st Edition

ISBN: 3319712721, 978-3319712727

More Books

Students also viewed these Databases questions

Question

Explain annealing process ?

Answered: 1 week ago