Question
For this problem, we must model the global averages in CO2 and N2O atmospheric concentrations. We will find the CO2 data, with its complete NOAA
For this problem, we must model the global averages in CO2 and N2O atmospheric concentrations. We will find the CO2 data, with its complete NOAA header, in the file named Data_NOAA_ESRL_CO2_trend_1980-2000 global.csv and the N2O data in the file Data_NOAA_ESRL_N2O_trend_2001-2022.txt.
For Data_NOAA_ESRL_CO2_trend_1980-2000 global.csv ( year eg1980 starts from A1 and month eg 1 starts from B1 and decimal eg1980.042 starts from C1 and average eg338.55 starts from D1 and trend eg 337.93 starts from E1)
For Data_NOAA_ESRL_N2O_trend_2001-2022.txt. ( the data is in textform instead of csv format)
Year eg2001 Month eg1 Decimal Average Average_unc Trend Trend_unc eg 0.2
eg values 2001 1 2001.042 316.3 0.2 316.0 0.2
Write a MATLAB no-input, no-output function to perform least squares regression on the provided data. We will model average CO2 (in ppm) as a function of decimal year and then model average N2O (in ppb) as a function of decimal year. The function must Perform linear regression on the data to get the least-squares coefficients, first for CO2 and then for N2O. Determine the predicted values of each linear model. Calculate SSE, SST, and r2 values for each model. Display the linear model equation (with clear variable names), SSE, SST, and r2 to the Command Window for each model. Make sure you can differentiate between the information for CO2 and N2O. Generate one figure with two subplots stacked vertically. On the top subplot, display the data and the trend line on the same axes for CO2. On the bottom subplot, display the data and trend line on the same axes for N2O. Format both subplots and the figure for technical presentation. -Learn about the xlim function to set the x-axis limits of both subplots. Make your subplots have identical axes limits on the x-axis and show all data in both subplots.
Q1. From your analyses, can you draw a conclusion about the accuracy of the data measurements? Provide justification for your answer. Q2. For which data set does a linear model best explain the variation that exists in the data? Clearly state the basis of your reasoning and provide justification for your answer.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started