Report - KENDRA KOFLER HOMEWORK 5 ME 2016 SECTION C SCRIPT...

Info icon This preview shows pages 1–2. Sign up to view the full content.

KENDRA KOFLER HOMEWORK 5 ME 2016 SECTION C SCRIPT: %%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Homework 5 %% ME 2016 Section C %% AUTHOR: Kendra Koflerb %%%%%%%%%%%%%%%%%%%% %% PURPOSE: The find a linear regression of GPS data points. The data %% points are found in the file GPS_data in the work folder. They are in %% the form of x and y coordinates with the x located in the first column %% and the y data located in the second column. The data is ploted on a %% graph, then a linear regression is formed in the following three ways: %% 1) y = ax + b 2) x = cy + d and finally 3) 1 = ex + fy. The %% line formed by these three ways are also plotted on the graph. The %% sum of squared errors is found for each of the three methods to allow %% for the interpretation of which found the "best" fit for the data. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%% %% ASSSUMPTIONS: %% 1)GPS_data is saved in the work folder %% 2)They are in the form of x and y coordinates with the x located in the %% first column and the y data located in the second column. %% 3)All the points are in the coordinate plane, therefore no z values can %% be used %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%5 %% Bring in the data from the excel file gpsdata=xlsread('GPS_data'); % the number of points will be equivalent to the length of the "gpsdata" n=length(gpsdata); % the x and y coordinates are given values x=gpsdata(:,1); y=gpsdata(:,2);
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern