CIND123 Module 6.2 Screen Capture

Similar documents
R Workshop Module 3: Plotting Data Katherine Thompson Department of Statistics, University of Kentucky

Types of Plotting Functions. Managing graphics devices. Further High-level Plotting Functions. The plot() Function

Intro to R Graphics Center for Social Science Computation and Research, 2010 Stephanie Lee, Dept of Sociology, University of Washington

Using Built-in Plotting Functions

IST 3108 Data Analysis and Graphics Using R Week 9

Statistical Programming with R

Overview. Lecture 13: Graphics and Visualisation. Graphics & Visualisation 2D plotting. Graphics and visualisation of data in Matlab

Statistical Software Camp: Introduction to R

Classes 7-8 (4 hours). Graphics in Matlab.

AA BB CC DD EE. Introduction to Graphics in R

Minitab Lab #1 Math 120 Nguyen 1 of 7

STAT STATISTICAL METHODS. Statistics: The science of using data to make decisions and draw conclusions

DSCI 325: Handout 18 Introduction to Graphics in R

Basics of Plotting Data

Data Visualization. Andrew Jaffe Instructor

Making Science Graphs and Interpreting Data

A (very) brief introduction to R

Plotting Complex Figures Using R. Simon Andrews v

INTRODUCTION TO R. Basic Graphics

Outline day 4 May 30th

Data Visualization in R

Logical operators: R provides an extensive list of logical operators. These include

Making Tables and Graphs with Excel. The Basics

Practical 2: Plotting

Introduction to R Programming

Graphics - Part III: Basic Graphics Continued

Descriptive Statistics, Standard Deviation and Standard Error

Organizing and Summarizing Data

Creating a Basic Chart in Excel 2007

R Graphics. Paul Murrell. The University of Auckland. R Graphics p.1/47

Module 10. Data Visualization. Andrew Jaffe Instructor

The Basics of Plotting in R

TMTH 3360 NOTES ON COMMON GRAPHS AND CHARTS

Chapter 2: Descriptive Statistics: Tabular and Graphical Methods

Data Visualization in R

Introduction to Excel Workshop

STATISTICS: AN INTRODUCTION USING R. By M.J. Crawley. Exercises 1. PLOTS: GRAPHICAL METHODS OF DATA EXPLORATION

An Introductory Guide to R

GO! with Microsoft PowerPoint 2016 Comprehensive

Introduction to MATLAB: Graphics

Surfing the Web Student Response

Reports, Graphs and Queries 1

Key Question. Focus. What are the geometric properties of a regular tetrahedron, and how do these compare to a bird tetrahedron?

Chapter 2: Understanding Data Distributions with Tables and Graphs

Bar Charts and Frequency Distributions

Graph tool instructions and R code

LAB 1 INSTRUCTIONS DESCRIBING AND DISPLAYING DATA

Section 2-2 Frequency Distributions. Copyright 2010, 2007, 2004 Pearson Education, Inc

The basic arrangement of numeric data is called an ARRAY. Array is the derived data from fundamental data Example :- To store marks of 50 student

Chapters 1.5 and 2.5 Statistics: Collecting and Displaying Data

Select Cases. Select Cases GRAPHS. The Select Cases command excludes from further. selection criteria. Select Use filter variables

Introduction to R and R-Studio Toy Program #1 R Essentials. This illustration Assumes that You Have Installed R and R-Studio

3. Data Analysis and Statistics

Display Lists in grid

Data Handling. Moving from A to A* Calculate the numbers to be surveyed for a stratified sample (A)

This module sets out essential concepts and skills relating to demonstrating competence in using presentation software.

PowerPoint Tables / Charts / Graphs

Creating and Modifying Charts

Name Date Types of Graphs and Creating Graphs Notes

An Introduction to R 2.2 Statistical graphics

Introduction to R. Hao Helen Zhang. Fall Department of Mathematics University of Arizona

Markov chain Monte Carlo methods

Assignments. Math 338 Lab 1: Introduction to R. Atoms, Vectors and Matrices

All Work should be in your Blue Book and Hardback Your previous tests throughout the year should also help with revision.

2.1: Frequency Distributions

CS Introduction to Computational and Data Science. Instructor: Renzhi Cao Computer Science Department Pacific Lutheran University Spring 2017

An Introduction to R Graphics

Package rafalib. R topics documented: August 29, Version 1.0.0

Using Charts in a Presentation 6

1B1a Arrays. Arrays. Indexing. Naming arrays. Why? Using indexing. 1B1a Lecture Slides. Copyright 2003, Graham Roberts 1

Statistics 251: Statistical Methods

Creating Google Maps. Chris Simpson MICFor 27 th September 2018

How to Read Your Degree Audit in Self-Service

Package visualizationtools

hp calculators HP 50g Working with Fast 3D Plots Plotting on the HP 50g The 2D/3D (PLOT SETUP) Form The Y= Form The WIN Form

limma: A brief introduction to R

Slides Prepared by JOHN S. LOUCKS St. Edward s s University Thomson/South-Western. Slide

Advanced Graphics with R

Introduction to Nesstar

The following is the Syllabus for Module 6, Presentation, which is the basis for the practice-based test in this module.

Lab 5: Matlab Tutorial Due Sunday, May 8 at midnight

Display Lists in grid

3. Mr. White does not wear white, so he is wearing the blue shirt. 4. Then Mr. Red wears a white shirt.

A Step-by-step guide to creating a Professional PowerPoint Presentation

Overview. Frequency Distributions. Chapter 2 Summarizing & Graphing Data. Descriptive Statistics. Inferential Statistics. Frequency Distribution

Graphing Method. Graph of x + y < > y 10. x

Week 2 Basic Statistical Concepts, Part II

Math 1505G, 2013 Graphs and Matrices

Statistical Tables and Graphs

DIGITRONIC MULTIPOINT AUTOCALIBRATION MANUAL

D&B Market Insight Release Notes. November, 2015

IBMSPSSSTATL1P: IBM SPSS Statistics Level 1

Choosing the right graph in Excel

Statistics Lecture 6. Looking at data one variable

COMP 102/112 : Test. 2019, Apr 1 ** WITH SOLUTIONS **

8. MINITAB COMMANDS WEEK-BY-WEEK

Report Builder Fields on Report Filters

25 Suggested Time: 30 min

More on Plots. Dmitry Adamskiy 30 Nov 2011

Special Note. This situation is arrives due to not showing the part boundaries of all parts on single screen at a time.

Transcription:

CIND123 Module 6.2 Screen Capture Hello, everyone. In this segment, we will discuss the basic plottings in R. Mainly; we will see line charts, bar charts, histograms, pie charts, and dot charts. Here is the.rmd file that is prepared for Module Six, and for each case, we will have an example [see Figure 1]. Figure 1 Let's start with line charts first. Let's define a vector "x", okay, here is our new vector, with nine values [c(1, 3, 6, 2, 8, 5, 10, 12, 13)], and if we run this command, you will see that the new variable is seen in the environment, and it is a numerical variable with nine entries [see Figure 2]. Figure 2 First, I want to introduce you the main plotting command in R, which is the plot command. "plot (x)" will give you the following graph [see Figure 3]. So this is a dot chart. You only see the points on the plotting region, okay. So here you only have the points. So, it is like for the first entry, entry number one, you have the value of "1". For entry number two, you have the value of "3", right. For entry number three, you should have the value "6". That's straightforward, for entry number three; you have the value of "6".

Figure 3 By just using the same plot command with different parameters, you can immediately go to a line chart. So here's my example for that. You take the "x" vector. When you say type- o" it will provide you the line segments, and when I say col= blue" I have the blue line segments connecting these points given for the "x" variable [see Figure 4]. Figure 4 So let's have a new variable "y" [c(2, 4, 5, 4, 12, 9, 11, 7, 10)]. "y" is a vector as well, and now I want to show you the lines command. So these lines commands will be combining the line segments for the vector "y", but this command will be providing the output on the same plot [lines(y, type= 0, pch=22, lty=2, col= red )]. So let's run it together. You will see that the new line segments are plotted on the graph that we had before [see Figure 5]. So here the parameters are, again, for "type=o", you have the line segments, and these are the different parameters that you can use. For example, here I wanted a red dashed line with square points. So "22" will go for "s" squared, for example.

Figure 5 Okay, so let's say that you want to go for a bar plot. So barplot(x, col= blue ), let's run this, and then let's have barplot(y, col= red"). Okay. So let's say that you want to have these two figures on an overall graph. So R makes it easy to combine multiple plots into one overall graph. And to do this, the simple command is "par. "par" will give you the number of rows and the number of columns. Actually, you give, okay, you write it down in terms of a vector. If you say "mfrow=c", this means that you want to have it on one row and two columns [par(mfrow=c(1, 2))]. So let's run this, and then I go to "barplot" for "x" and "barplot" for "y", okay, and R is providing these two graphs on overall one graph [see Figure 6]. Figure 6

Now, let's pass the histograms, but before passing the histograms, let's write "dev.off" here as a command, so that "par" will not be active anymore. Otherwise, while you're drawing your histograms, "par" will be still active, and you will see all your histograms in one row and two columns. Okay, so let's graph the distribution of "x" by using a histogram [hist(x)]. This is the output that you get, and by default, you have the title written as "Histogram of x," and you can also see the frequency here and the variable "x" [se Figure 7]. Figure 7 And we can change the colour if you like. We can go to blue [col= blue ]. And if you use the main parameter here [main= distribution of x ], we will see that the title is changed by that parameter. So here I have "distribution of x" as a title [see Figure 8]. Figure 8

And let's go to pie charts. "pie(x)" will provide you the pie chart [see Figure 9]. And here you see that the colours are different for each and every slice, and it is by default. It is easy to see the different slices by these different colours. Figure 9 And, when you pass to dot chart, okay, this is the graph that you will get [see Figure 10]. And it is very similar to the one that we have provided with the plot command. If you write "plot", you see that it is a dot chart, and it is very similar to the dot chart command [see Figure 3]. Figure 10 End of CIND123 Module 6 Screen Capture