 Statistics package  Graphics package  Programming language  Can be used to share/reproduce analyses  Many new packages being created - can be downloaded.

Slides:



Advertisements
Similar presentations
Introduction to Eclipse. Start Eclipse Click and then click Eclipse from the menu: Or open a shell and type eclipse after the prompt.
Advertisements

Introduction to Microsoft Office 2007 with focus on MS Word
Microsoft Office Illustrated Fundamentals Unit C: Getting Started with Unit C: Getting Started with Microsoft Office 2010 Microsoft Office 2010.
 Use the Left and Right arrow keys or the Page Up and Page Down keys to move between the pages. You can also click on the pages to move forward.  To.
StaffOnline The New Look & Feel January StaffOnline Introduction In keeping up with new technology the StaffOnline has a new look and feel. This.
Introduction to GTECH 201 Session 13. What is R? Statistics package A GNU project based on the S language Statistical environment Graphics package Programming.
Using Pine to send your ICS111 homework First Log in into UNIX using SSH either from home (If you have previously installed SSH or from the Lab. Once in.
Paint Shop Tutorial. Essential Overview New Corel Paint Shop Pro Photo X2 is the ideal choice for any aspiring photographer's digital darkroom. It's filled.
The Internet. Telnet Telnet means using your computer as a terminal. All commands you type are sent to the host computer you are connected to and executed.
1 of 6 This document is for informational purposes only. MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS DOCUMENT. © 2007 Microsoft Corporation.
Installation on Windows Vista/Windows 7 NOTE: Installation on Windows Vista can differ depending on the version of Windows installed​ ​ In most computers.
Installation on Windows Vista/Windows 7 NOTE: Installation on Windows Vista can differ depending on the version of Windows installed​ ​ In most computers.
How to Use the R Programming Language for Statistical Analyses Part I: An Introduction to R Jennifer Urbano Blackford, Ph.D. Department of Psychiatry Kennedy.
Command Console Tutorial BCIS 3680 Enterprise Programming.
UNIX By Darcy Tatlock. 1. Successful Log Into Unix To actively manipulate your website you need to be logged in. Without being logged in you cannot enter.
Introduction to R Statistical Software Anthony (Tony) R. Olsen USEPA ORD NHEERL Western Ecology Division Corvallis, OR (541)
2. Introduction to the Visual Studio.NET IDE 2. Introduction to the Visual Studio.NET IDE Ch2 – Deitel’s Book.
Digital Image Processing Lecture3: Introduction to MATLAB.
LGC Website and Customer On-line Tools LGC RESOURCE 2014.
Unix Primer. Unix Shell The shell is a command programming language that provides an interface to the UNIX operating system. The shell is a “regular”
XP New Perspectives on Introducing Microsoft Office XP Tutorial 1 1 Introducing Microsoft Office XP Tutorial 1.
1 Lesson 6 Exploring Microsoft Office 2007 Computer Literacy BASICS: A Comprehensive Guide to IC 3, 3 rd Edition Morrison / Wells.
XP New Perspectives on Browser and Basics Tutorial 1 1 Browser and Basics Tutorial 1.
Microsoft PowerPoint Getting Started Guide Prepared for Towson University Dr. Jeff M. Kenton Amy Chase Martin 2007.
MICROSOFT WORD GETTING STARTED WITH WORD. CONTENTS 1.STARTING THE PROGRAMSTARTING THE PROGRAM 2.BASIC TEXT EDITINGBASIC TEXT EDITING 3.SAVING A DOCUMENTSAVING.
CHAPTER 9 Introducing Microsoft Office Learning Objectives Start Office programs and explore common elements Use the Ribbon Work with files Use.
Objectives Understand what MATLAB is and why it is widely used in engineering and science Start the MATLAB program and solve simple problems in the command.
CHAPTER 9 Introducing Microsoft Office Learning Objectives Start Office programs and explore common elements Use the Ribbon Work with files Use.
®® Microsoft Windows 7 for Power Users Tutorial 13 Using the Command-Line Environment.
Chapter Three The UNIX Editors. 2 Lesson A The vi Editor.
1 Lab of COMP 406 Teaching Assistant: Pei-Yuan Zhou Contact: Lab 1: 12 Sep., 2014 Introduction of Matlab (I)
Alice 2.0 Introductory Concepts and Techniques Project 1 Exploring Alice and Object-Oriented Programming.
Piotr Wolski Introduction to R. Topics What is R? Sample session How to install R? Minimum you have to know to work in R Data objects in R and how to.
Booting Ubuntu Linux Live CSCI 130 – Fall 2008 Action Lab Dr. W. Jones.
Active-HDL Interfaces Debugging C Code Course 10.
Getting Started with MATLAB 1. Fundamentals of MATLAB 2. Different Windows of MATLAB 1.
CMPS 1371 Introduction to Computing for Engineers MatLab.
Lesson 2-Touring Essential Programs. Overview Development of UNIX and Linux. Commands to execute utilities. Communicating instructions to the shell. Navigating.
Chapter 3 MATLAB Fundamentals Introduction to MATLAB Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Unix and Samba By: IC Labs (Raj Kidambi). What is Unix?  Unix stands for UNiplexed Information and Computing System. (It was originally spelled "Unics.")
1 Getting Started with C++. 2 Objective You will be able to create, compile, and run a very simple C++ program on Windows, using Visual Studio 2008.
Lesson No: 6 Introduction to Windows XP CHBT-01 Basic Micro process & Computer Operation.
Chapter Three The UNIX Editors.
Introduction to R Introductions What is R? RStudio Layout Summary Statistics Your First R Graph 17 September 2014 Sherubtse Training.
XP Browser and Basics COM111 Introduction to Computer Applications.
®® Microsoft Windows 7 for Power Users Tutorial 3 Managing Folders and Files.
More Unix Naomi Altman. Directories Directory = folder mkdir - makes a new directory rmdir - removes an empty directory cd mydirectory - moves you into.
Computer Literacy BASICS: A Comprehensive Guide to IC 3, 5 th Edition Lesson 3 Windows File Management 1 Morrison / Wells / Ruffolo.
Python Lesson 1 1. Starter Create the following Excel spreadsheet and complete the calculations using formulae: 2 Add A1 and B1 A2 minus B2 A3 times B3.
1 Getting Started with C++ Part 1 Windows. 2 Objective You will be able to create, compile, and run a very simple C++ program on Windows, using Microsoft.
NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS ( NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS (PRACTICAL PART) Tutorial 2 : Matlab - Getting Started.
Microsoft Office 2008 for Mac – Illustrated Unit D: Getting Started with Safari.
Introductory Data Analysis F73DA2. Contact Times (Spring Term 2008) Monday 4: : Lecture in LT3 Tuesday 2: : Lecture in LT3 Wednesday
MATLAB (Matrix Algebra laboratory), distributed by The MathWorks, is a technical computing environment for high performance numeric computation and.
Fundamentals of Windows Mouse n 4 Basic Operations: –Pointing –Clicking –Double Clicking –Dragging.
Refworks Part I.
Getting Started with Application Software
Release Numbers MATLAB is updated regularly
The Command Prompt Commands are the way to “do things” in Unix
Guide To UNIX Using Linux Third Edition
Operating Microcomputer
Introducing Microsoft Office 2010
Windows Internet Explorer 7-Illustrated Essentials
Introduction Paul Flynn
Digital Image Processing
CSCI N317 Computation for Scientific Applications Unit 1 – 1 MATLAB
Amos Introduction In this tutorial, you will be briefly introduced to the student version of the SEM software known as Amos. You should download the current.
Scripts In Matlab.
Microsoft Office Illustrated Fundamentals
Executive Reports, Instructions and Documentation
Presentation transcript:

 Statistics package  Graphics package  Programming language  Can be used to share/reproduce analyses  Many new packages being created - can be downloaded and easily installed  Largely text-based interface Introduction to the R language What is R?

 Statistical and numerical methods  High quality visualization and graphics tools  Effective, extensible user interface  Compiles and runs on UNIX, Windows and Macs  Open source i.e., freely software Strengths of R

 Software, documentation, manuals and support:  More information about RR  The Comprehensive R Archive NetworkComprehensive R Archive Network  The 'official' introduction to R'official' introduction to R R software

 R has several packages available  R has more than 1000 functions and commands  It is impossible to remember them all  Each function may also take several arguments  One needs to use the help system and manuals regularly Working with R

 Once R is installed on your system, click on the R icon  Upon opening, you will see the following console window: Getting started

 The R program issues a prompt ‘>’ when it expects input commands  E.g., type in 2+2 and press the enter key  You will see: Prompt and Command line > 2+2 [1] 4 > The result is 4. The [1] says “first requested element will follow”. Here, there is just one element. The prompt returns waiting for further input. The result is 4. The [1] says “first requested element will follow”. Here, there is just one element. The prompt returns waiting for further input.

 For each “project” on which one works one should use a different directory (=folder)  At the end of each session, R asks whether one wants to save the workspace image - all objects are saved  On double clicking on a workspace image file, R starts and loads the workspace - all objects are restored  When the workspace image is saved, the history of recently typed commands is saved Some peculiarities of R

 The workspace stores all commands  Previous commands can be retrieved using the up/down arrows  R is case sensitive  Using UNIX platforms, UNIX commands can be used: Elementary R mkdir test -> make directory called test cd test-> change to test directory mkdir test -> make directory called test cd test-> change to test directory  Using windows, use the File menu to open and save files, or change directories

 Excel files should first be saved as tab-delimited text files, before they can be read into R  In R, the full pathname of files should be specified – go to the File menu, change directories to specify the location of the file to be opened  Open files with filenames and their extentions  See R Data Import/Export manuals in the Help menu Importing Data

So, to view a tab-delimited file, stored on your desktop: 1.Set directory in the File menu 2.At the prompt, type:read.delim(“filename.txt") 3.The data will now be shown on the R console 4.Naming the datafile: x=read.delim(“filename.txt") Importing Data - example Various ways of reading in the files > x = read.delim(“filename.txt”) > x <- read.table (“filename.txt”) > x <- read.csv (“filename.txt”)

 The exit or quit command is > q()  OR click on the File menu and then on Exit  OR click on the X in the top right hand corner of the R window  Remember, there will be a message asking whether to save the workspace image. Clicking Yes (the safe option) will save all the objects that remain in the workspace – any that were there at the start of the session and any that have been added since. Saving and Quitting

 You may have the same variable names within two different datasets, and so it’s necessary to attach a dataset: attach(filename)  When you ask R to use a value of a variable it needs to find, R searches through several ``environments'' for these variables  By attaching a data frame, you put the names into the second environment searched (the name of the dataframe is in the first). These are masked by any variables which already have the same name Attaching files

Important things to remember:  You can change the values of the variables in the data frame, but you must remember to reference the data frame  Variables removed from unattached files, will not be visible when listing variables (where ls() lists all known variables), but those variables in fact still there  You must detach the dataset between uses of these variables, or you may forget which variable you are referring to: detach(filename) Attaching and detaching files

Getting Help > help ( ) provides help on how to use ‘help’ > help (topic)provides help on a specific topic > help.start ( )opens R documentation on the internet > help ( ) provides help on how to use ‘help’ > help (topic)provides help on a specific topic > help.start ( )opens R documentation on the internet  Various options are available on the help function  Also, use the help menu  This is incredibly useful – get to know it and use it!

R as a calculator  R will evaluate basic calculations which are typed into the console (input window)  Try a few examples ….

Value Assignments  Values can be assigned using the <- operator, which consists of the two characters ‘<’ (“less than”) and ‘-’ (“minus”) occurring side-by-side, and it ‘points’ to the object receiving the value of the expression.  Example: > x <- 10 > y <- 20 > x + y [1] 30 > variables

Value Assignments  More complicated calculations  To obtain the number (or other value) stored in any letter: - type the letter followed by enter - type print (letter) - type show (letter)

Simple operations Try some of these simple operations:  Add:  Multiply: 10 * 20  Divide: 10/20  Raise to a power: 10 ** 20