Presentation is loading. Please wait.

Presentation is loading. Please wait.

EGR 115 Introduction to Computing for Engineers 2D Plotting – Part II Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers.

Similar presentations


Presentation on theme: "EGR 115 Introduction to Computing for Engineers 2D Plotting – Part II Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers."— Presentation transcript:

1 EGR 115 Introduction to Computing for Engineers 2D Plotting – Part II Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers

2 Lecture Outline Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers Annotation of Plots Polar, Bar, Pie, … Plots Slide 2 of 13

3 2D Plotting Annotation of Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers Slide 3 of 13

4 2D Plotting Annotation of Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers Editing a Plot  Click on “Edit Plot”  Right click on the red line and make it dashed  Click on the “Show Plot Tools” (far right) icon o Select ant item in the plot window to see properties of that item. o Change the location of the legend to be the lower left corner Slide 4 of 13

5 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Vertical Bar Graph: Slide 5 of 13 % An in class example of Additional Plots x=[1 2 3 4 5 6 7 8]; y = 10 * rand(1, length(x)); % Bar Plot figure bar(x,y) title('Example of a Vertical Bar Plot') xlabel('x') ylabel('y') … MATLAB Code:

6 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Horizontal Bar Graph: Slide 6 of 13 barh(x,y) title('Example of a Horizontal Bar Plot') xlabel('y') ylabel('x') MATLAB Code:

7 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Stem Graph: Slide 7 of 13 stem(x,y) title('Example of a Stem Plot') xlabel('x') ylabel('y') MATLAB Code:

8 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Stair Graph: Slide 8 of 13 stairs(x,y) title('Example of a Stair Plot') xlabel('x') ylabel('y') MATLAB Code:

9 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Compass Plot: Slide 9 of 13 compass(x,y) title('Example of a Compass Plot') xlabel('x') ylabel('y') MATLAB Code:

10 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers A Pie Graph: Slide 10 of 13 pie(y) title('Example of a Pie Plot') MATLAB Code:

11 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers An Exploded Pie Graph: Slide 11 of 13 explode = [0 1 1 0 0 1 0 1]; pie(y, explode) title('Example of an Exploded Pie Plot') MATLAB Code:

12 2D Plotting Additional 2D Plots Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers Slide 12 of 13 You will need to use the graph to determine k

13 Next Lecture Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers Designing The Battleship Game in MATLAB Slide 13 of 13


Download ppt "EGR 115 Introduction to Computing for Engineers 2D Plotting – Part II Friday 19 Sept 2014 EGR 115 Introduction to Computing for Engineers."

Similar presentations


Ads by Google