Answered step by step
Verified Expert Solution
Question
1 Approved Answer
6. In this problem, we investigate different growth models on a set of exper imental data. In the attached csv files (mass.csu, times.csu, samples.csu, and
6. In this problem, we investigate different growth models on a set of exper imental data. In the attached csv files (mass.csu, times.csu, samples.csu, and stdevs.csv), growth kinetics of Fortner Plasmacytoma 1 tumors from tumorigeneic mouse models are provided. The four data sets represent temporal data (days) of mean tumor mass (mgs) over a number of different mice (the number of mice at each data point is contained in samples.csv, with corresponding standard deviation in stdevs.csv) (a) Plot the data, including errors bars representing the sample standard deviation: The following (incomplete) code may be useful: clear all; close al1; % Read in the data times-csvread (times.csv') mass- stdevs- samples-i % standard error error- % plot with error bars figure (1) errorbar (times, mass, error, 'ok') hold on xlabel ('time (days) ylabel ('tumor mass (mg)' (b) Now, fit a Gompertz growth equation to the data set. That is, find parameters a and b, with dN which (locally) minimize the residual where N; represents the experimental data measured at t-t, and N(t; a, b) is the model (i.e. the solution of the ODE at time t witlh parameters a and b). Note the i in the denominator to weight terms according to their overall variance (large contributes less to the min- imization) This can be accomplished relatively easily in MATLAB, in a number of different ways. One way is to utilize the built-in function fminsearch. You will probably need to construct three m-files (i) One with ODE right-hand side, i.e. vector field (say gompertz.m, a function), one which evaluates the error between the model and the data, given by E(a, b) above (say errorGompertz.m, a function), (ii) (iii) and a driver, which which call the minimization procedure fmin- search. For the driver (part (ii)), the following can be used to solve for the parameters and plot the model %Now fit the data %include initial guess a0-1 bo-0.5 params0-[a0, b0] % Call MATLAB minimization fminsearch min is the optimized parameters (vector [a,b)) err is the difference in E between data and model at optimized parameters min min,err] -fminsearch (8 (params) error-gompertz (params, times, mass,error), params0, optimset'Tol a-opt min(1) b.opt- min (2) % solve Gompertz equation with computed parameters [T opt, N_opt]-ode23s (8gompertz, times, mass (1), , a opt,b.opt) plot (T-opt, N-opt,"-b,'LineWidth',2); I am not including everything here, but most can be accomplished in a short amount of code. (i) involves just writing the vector field, as in HW #1, and (ii) requires you to solve the ODE on the time interval indicated in times.csv, and then find the net error E(a, b) (it should return this). Plot the experimental data together with the Gompertz fit obtained Indicate your values for a andb (c)Do the same, but for exponential growth. That is, repeat the analysis from (b), except assuming here that N satisfies the ODIE dN dt Note here you will want to find one parameter, k (d) What are the respective errors for each of the two models? Which does better? e) What do they each predict for the tumor size at 30 days? times.csv IRead-Onlyl -Excel Insert Page Layout FormulasData Review View Team Tell me what you want to do Sign in Share AutoSum , E Copy Fill Conditional Format as Neutral Formatting Insert Delete Format B 1 u Merge & Center, $, % , Sort &Find & ilter Select - Check Cell Format Painter 21 26 stdevs.csv (Read-Ontyl - Excel Insert Page Layout Formulas Data Review View Team Tell me what you want to do. Sign in Share -9- AutoSun @wrap Tet General Copy Fill Lc 19 .. -E--Merge & Center. $. % , 'il-E Conditional Format as Good Insert Delete Format Sort & Find & Fiter Select B 1 u ormet Painter& A . Clear Formatting A1 173 381 1164 2591 2567 176 3278 3371 3737 3704 6279 mass.csw [Read Onlyl Excel Insert Page LayoutFormulas Data ReviewViewTeam ? Tell me what you want to do. Sign in Share Cut 11. Ar A. - 9-: wrap Tet rma Bad Good AutoSum -A EE Insert Delete Format Fill ClearSort & Find& Editing B l u . w . 10. .---| Merge & Center . $ . 96 , %:Conditional Format as Neutral Check Cell Flter Select Clipboard 400 521440 1251 4638 3780 4377 59165940 8762 713130 11600 97351120 13585 14170 16550 17970 19865 + 100% semples.csv [Read-Onlyl -Excel 201 Ls 71 58 21 15 samples 6. In this problem, we investigate different growth models on a set of exper imental data. In the attached csv files (mass.csu, times.csu, samples.csu, and stdevs.csv), growth kinetics of Fortner Plasmacytoma 1 tumors from tumorigeneic mouse models are provided. The four data sets represent temporal data (days) of mean tumor mass (mgs) over a number of different mice (the number of mice at each data point is contained in samples.csv, with corresponding standard deviation in stdevs.csv) (a) Plot the data, including errors bars representing the sample standard deviation: The following (incomplete) code may be useful: clear all; close al1; % Read in the data times-csvread (times.csv') mass- stdevs- samples-i % standard error error- % plot with error bars figure (1) errorbar (times, mass, error, 'ok') hold on xlabel ('time (days) ylabel ('tumor mass (mg)' (b) Now, fit a Gompertz growth equation to the data set. That is, find parameters a and b, with dN which (locally) minimize the residual where N; represents the experimental data measured at t-t, and N(t; a, b) is the model (i.e. the solution of the ODE at time t witlh parameters a and b). Note the i in the denominator to weight terms according to their overall variance (large contributes less to the min- imization) This can be accomplished relatively easily in MATLAB, in a number of different ways. One way is to utilize the built-in function fminsearch. You will probably need to construct three m-files (i) One with ODE right-hand side, i.e. vector field (say gompertz.m, a function), one which evaluates the error between the model and the data, given by E(a, b) above (say errorGompertz.m, a function), (ii) (iii) and a driver, which which call the minimization procedure fmin- search. For the driver (part (ii)), the following can be used to solve for the parameters and plot the model %Now fit the data %include initial guess a0-1 bo-0.5 params0-[a0, b0] % Call MATLAB minimization fminsearch min is the optimized parameters (vector [a,b)) err is the difference in E between data and model at optimized parameters min min,err] -fminsearch (8 (params) error-gompertz (params, times, mass,error), params0, optimset'Tol a-opt min(1) b.opt- min (2) % solve Gompertz equation with computed parameters [T opt, N_opt]-ode23s (8gompertz, times, mass (1), , a opt,b.opt) plot (T-opt, N-opt,"-b,'LineWidth',2); I am not including everything here, but most can be accomplished in a short amount of code. (i) involves just writing the vector field, as in HW #1, and (ii) requires you to solve the ODE on the time interval indicated in times.csv, and then find the net error E(a, b) (it should return this). Plot the experimental data together with the Gompertz fit obtained Indicate your values for a andb (c)Do the same, but for exponential growth. That is, repeat the analysis from (b), except assuming here that N satisfies the ODIE dN dt Note here you will want to find one parameter, k (d) What are the respective errors for each of the two models? Which does better? e) What do they each predict for the tumor size at 30 days? times.csv IRead-Onlyl -Excel Insert Page Layout FormulasData Review View Team Tell me what you want to do Sign in Share AutoSum , E Copy Fill Conditional Format as Neutral Formatting Insert Delete Format B 1 u Merge & Center, $, % , Sort &Find & ilter Select - Check Cell Format Painter 21 26 stdevs.csv (Read-Ontyl - Excel Insert Page Layout Formulas Data Review View Team Tell me what you want to do. Sign in Share -9- AutoSun @wrap Tet General Copy Fill Lc 19 .. -E--Merge & Center. $. % , 'il-E Conditional Format as Good Insert Delete Format Sort & Find & Fiter Select B 1 u ormet Painter& A . Clear Formatting A1 173 381 1164 2591 2567 176 3278 3371 3737 3704 6279 mass.csw [Read Onlyl Excel Insert Page LayoutFormulas Data ReviewViewTeam ? Tell me what you want to do. Sign in Share Cut 11. Ar A. - 9-: wrap Tet rma Bad Good AutoSum -A EE Insert Delete Format Fill ClearSort & Find& Editing B l u . w . 10. .---| Merge & Center . $ . 96 , %:Conditional Format as Neutral Check Cell Flter Select Clipboard 400 521440 1251 4638 3780 4377 59165940 8762 713130 11600 97351120 13585 14170 16550 17970 19865 + 100% semples.csv [Read-Onlyl -Excel 201 Ls 71 58 21 15 samples
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