[Solved]Lab Assignment 6 Csci 251 Lab 6 Use Xy Scatterplot Graph Cholesterol Data File Cholesterol Q37256112
Matlab Programming–need help with this assignment



![Cholesterol [Read-Only] Excel Insert Page Layout Formulas Data Review View Help Tell me what you want to do File Home Cut Wra](https://media.cheggcdn.com/media%2F41a%2F41a8a06e-76c7-491a-9353-d00889fe10c3%2FphpW6dN3J.png)


Lab Assignment 6 CSCI 251 For Lab 6, you will use an xy-scatterplot to graph cholesterol data from the file Cholesterol.csv (comma delimited file) as follows: Cholesterol Fall 2018 220 LDL Cholesterol VLDL Cholesterol HDL Cholesterol Triglycerides 200 _+ 180 160 140 120 100 80 60 20 2010 2014 2007 2008 2009 2011 2012 2013 2006 You will not create a new file but instead download and edit graphChol.m to include the above plot, including marker styles. Code has already been provided that reads the data from Cholesterol.csv and populates the numVal array: numVal array You will not create a new file but instead download and edit graphChol.m to include the above plot, including marker styles. Code has already been provided that reads the data from Cholesterol.csv and populates the numVal array: numVal array 2008 2009 95 42 39 209 2013 2014 2006 95 30 42 149 2007 2010 2011 114 29 39 147 2012 109 95 120 126 120 35 30 43 40 43 36 151 166 164 167 176 110 You should run the file and in MATLAB’s workspace window, and click on numVal to verify the above data You will need to provide code using MATLAB’s plotting commands as stated in graphChol.m, approximately lines 18 -26 and lines 31-41. As shown in the figure, the four lines should be formatted as follows: As shown in the figure, the four lines should all be solid lines formatted as follows: Sample Output in Command Window (figure is above; my keyboard entry is bold and underlined): Enter the pixel-width of the lines (1-10): 1 For LDL Cholesterol choose one of the following line colors: g green r red c cyan m magenta y yellow k black w white Now, choose the line style for LDL Cholesterol: solid : dotted -. dashdot dashed [space] for no line — For VLDL Cholesterol choose one of the following line colors: g green r red c cyan m magenta y yellow k black w white Now, choose the line style for VLDL Cholesterol Cholesterol [Read-Only] Excel Insert Page Layout Formulas Data Review View Help Tell me what you want to do File Home Cut Wrap Text Calibri General ECopy o Conditional Format as Cell FormattingTableStyles Paste Insert Delet B 1 u . m . 2 . A. $. % , Merge & Center . Format Painter B IU 00 +0 Clipboard Number Font Alignment Cells x 2006 95 109 149 164 167 209 176 147 110 151 166 2006 42 43 36 39 2008 2009 2010 2011 2012 42 35 29 95 114 120 126 120 39 43 2014 10 12 13 15 16 17 18 clear clc clf oneLine . i-1; Open comma-separated file fhfopen ( Cholesterol.csv’, r’ Read in one line at a time and build the numai array while feof (fh) oneLine-fgetl (fh); token textscan (oneLine, ‘ %d’, ‘delimiter’ , numValnumVal tokeni)]; ‘,’ ) ; end %Define length of x – look at the data file (how many points on each line) %Add title %Prompt for the four line colors and styles 888888888888888888888888888888888888器8888888888888888888888888888음 set (gca, XTick’,1:length (numVal)); set (gca, ‘XTickLabel’,numVal (1,:)); %On SAME graph, plot Triglycerides, HDL Cholesterol, %VLDL Cholesterol, and LDL Cholesterol %use both the line color and style as entered by user, llse marker stvle according to lah instructions numVal-(numVal token i)) end 88888888888888888888888888888888888888888888음8888888888888888888888 Define length of x – look at the data file (how many points on each line) %Add title Prompt for the four line colors and styles 용용음용용욤욤욤욤용용욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤용음용음용 용용용용용음용용음용용음용용음용용욤욤욤욤욤욤욤욤욤욤욤용용용용용 set (gca, “XTǐck’ , 1: length ( numval) ) ; set (gca, ‘XTickLabel’,numVal 1,:)) On SAME graph, plot Triglycerides, HDL Cholesterol, %VLDL Cholesterol, and LDL Cholesterol Use both the line color and style as entered by user) %Use marker style according to lab instructions %Marker face colors must be filled in and the same as the line color %Add a legend in upperright corner 욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤음용음음용음음용욤욤욤욤욤욤욤욤욤욤욤욤용음음용음응용음응용음음용 Show transcribed image text Lab Assignment 6 CSCI 251 For Lab 6, you will use an xy-scatterplot to graph cholesterol data from the file Cholesterol.csv (comma delimited file) as follows: Cholesterol Fall 2018 220 LDL Cholesterol VLDL Cholesterol HDL Cholesterol Triglycerides 200 _+ 180 160 140 120 100 80 60 20 2010 2014 2007 2008 2009 2011 2012 2013 2006 You will not create a new file but instead download and edit graphChol.m to include the above plot, including marker styles. Code has already been provided that reads the data from Cholesterol.csv and populates the numVal array: numVal array
You will not create a new file but instead download and edit graphChol.m to include the above plot, including marker styles. Code has already been provided that reads the data from Cholesterol.csv and populates the numVal array: numVal array 2008 2009 95 42 39 209 2013 2014 2006 95 30 42 149 2007 2010 2011 114 29 39 147 2012 109 95 120 126 120 35 30 43 40 43 36 151 166 164 167 176 110 You should run the file and in MATLAB’s workspace window, and click on numVal to verify the above data You will need to provide code using MATLAB’s plotting commands as stated in graphChol.m, approximately lines 18 -26 and lines 31-41. As shown in the figure, the four lines should be formatted as follows: As shown in the figure, the four lines should all be solid lines formatted as follows:
Sample Output in Command Window (figure is above; my keyboard entry is bold and underlined): Enter the pixel-width of the lines (1-10): 1 For LDL Cholesterol choose one of the following line colors: g green r red c cyan m magenta y yellow k black w white Now, choose the line style for LDL Cholesterol: solid : dotted -. dashdot dashed [space] for no line — For VLDL Cholesterol choose one of the following line colors: g green r red c cyan m magenta y yellow k black w white Now, choose the line style for VLDL Cholesterol
Cholesterol [Read-Only] Excel Insert Page Layout Formulas Data Review View Help Tell me what you want to do File Home Cut Wrap Text Calibri General ECopy o Conditional Format as Cell FormattingTableStyles Paste Insert Delet B 1 u . m . 2 . A. $. % , Merge & Center . Format Painter B IU 00 +0 Clipboard Number Font Alignment Cells x 2006 95 109 149 164 167 209 176 147 110 151 166 2006 42 43 36 39 2008 2009 2010 2011 2012 42 35 29 95 114 120 126 120 39 43 2014 10 12 13 15 16 17 18
clear clc clf oneLine . i-1; Open comma-separated file fhfopen ( Cholesterol.csv’, r’ Read in one line at a time and build the numai array while feof (fh) oneLine-fgetl (fh); token textscan (oneLine, ‘ %d’, ‘delimiter’ , numValnumVal tokeni)]; ‘,’ ) ; end %Define length of x – look at the data file (how many points on each line) %Add title %Prompt for the four line colors and styles 888888888888888888888888888888888888器8888888888888888888888888888음 set (gca, XTick’,1:length (numVal)); set (gca, ‘XTickLabel’,numVal (1,:)); %On SAME graph, plot Triglycerides, HDL Cholesterol, %VLDL Cholesterol, and LDL Cholesterol %use both the line color and style as entered by user, llse marker stvle according to lah instructions
numVal-(numVal token i)) end 88888888888888888888888888888888888888888888음8888888888888888888888 Define length of x – look at the data file (how many points on each line) %Add title Prompt for the four line colors and styles 용용음용용욤욤욤욤용용욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤용음용음용 용용용용용음용용음용용음용용음용용욤욤욤욤욤욤욤욤욤욤욤용용용용용 set (gca, “XTǐck’ , 1: length ( numval) ) ; set (gca, ‘XTickLabel’,numVal 1,:)) On SAME graph, plot Triglycerides, HDL Cholesterol, %VLDL Cholesterol, and LDL Cholesterol Use both the line color and style as entered by user) %Use marker style according to lab instructions %Marker face colors must be filled in and the same as the line color %Add a legend in upperright corner 욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤욤음용음음용음음용욤욤욤욤욤욤욤욤욤욤욤욤용음음용음응용음응용음음용
Expert Answer
Answer to Lab Assignment 6 CSCI 251 For Lab 6, you will use an xy-scatterplot to graph cholesterol data from the file Cholesterol…. . . .
OR

