Programming For Big Data

Slides:



Advertisements
Similar presentations
COMPUTER PROGRAMMING Task 1 LEVEL 6 PROGRAMMING: Be able to use a text based language like Python and JavaScript & correctly use procedures and functions.
Advertisements

CIT 590 Intro to Programming Lecture 1. By way of introduction … Arvind Bhusnurmath There are no bonus points for pronouncing my last name correctly Please.
Scripting Languages. Originally, a script was a file containing a sequence of commands that needed to be executed Control structures were added to make.
 2002 Prentice Hall. All rights reserved. 1 Chapter 2 – Introduction to Python Programming Outline 2.1 Introduction 2.2 First Program in Python: Printing.
Introduction to Python. What is Python? Interpreted object oriented high level programming language – No compiling or linking neccesary Extensible: add.
The Python Programming Language Matt Campbell | Steve Losh.
By. What advantages has it? The Reasons for Choosing Python  Python is free  It is object-oriented  It is interpreted  It is operating-system independent.
Introduction to Python (for C++ programmers). Background Information History – created in December 1989 by Guido van Rossum Interpreted Dynamically-typed.
Python.
V Avon High School Tech Club Agenda Old Business –Delete Files New Business –Week 16 Topics: Intro to HTML/CSS –Questions? Tech Club Forums.
Python Programming Fundamentals
Introduction to Programming Workshop 1 PHYS1101 Discovery Skills in Physics Dr. Nigel Dipper Room 125d
Computer Science 111 Fundamentals of Programming I Overview of Programming.
Copyright © 2012 Pearson Education, Inc. Publishing as Pearson Addison-Wesley C H A P T E R 6 Value- Returning Functions and Modules.
PYTHON. Python is a high-level, interpreted, interactive and object- oriented scripting language. Python was designed to be highly readable which uses.
Introduction to PythonIntroduction to Python SPARCS `08 서우석 (pipoket) `09 Summer SP ARCS Seminar`09 Summer SP ARCS Seminar.
Guide to Programming with Python Chapter One Getting Started: The Game Over Program.
Python – May 11 Briefing Course overview Introduction to the language Lab.
Intro to Python Adriane Huber Debbie Bartlett Python Lab #1Python Lab #1 1.
1 Computer Science of Graphics and Games MONT 105S, Spring 2009 Session 1 Simple Python Programs Using Print, Variables, Input.
Introducing Python CS 4320, SPRING Resources We will be following the Python tutorialPython tutorial These notes will cover the following sections.
C463 / B551 Artificial Intelligence Dana Vrajitoru Python.
Python. History of python  Python was conceived in the late 1980s and its implementation was started in December 1989 by Guido van Rossum at CWI in the.
Midterm Exam Topics (Prof. Chang's section) CMSC 201.
Exploring Spyder: An IDE for scientific computing
Getting Started With Python Brendan Routledge
Quiz 1 A sample quiz 1 is linked to the grading page on the course web site. Everything up to and including this Friday’s lecture except that conditionals.
Python Joseph Eckstrom, Benjamin Moore, Willis Kornegay.
Part 1 Learning Objectives To understand that variables are a temporary named location to store data and that programmers work with different data types.
Indentations makes the scope/block Function definition def print_message (): print “hello” Function usages print_message () hubo.move ()// hubo is a class.
PROBLEM SOLVING WARM-UP Fill in the spaces using any operation to solve the following (!, (), -/+,÷,×): = 6.
PYTHON PROGRAMMING LANGUAGE.
Introduction to python programming
Fundamentals of Programming I Overview of Programming
PH2150 Scientific Computing Skills
Python Programming Unit -1.
CST 1101 Problem Solving Using Computers
Whatcha doin'? Aims: To start using Python. To understand loops.
Python: Experiencing IDLE, writing simple programs
Data Types Variables are used in programs to store items of data e.g a name, a high score, an exam mark. The data stored in a variable is entered from.
Introduction to Python
Introduction Python is an interpreted, object-oriented and high-level programming language, which is different from a compiled one like C/C++/Java. Its.
Intro To Pete Alonzi University of Virginia Library
Variables, Expressions, and IO
Python is a general-purpose interpreted, interactive, object-oriented, and high-level programming language. It was created by Guido van Rossum during.
Functions CIS 40 – Introduction to Programming in Python
1 Python Lab #1 Intro to Python Adriane Huber Debbie Bartlett.
Lesson 1 Learning Objectives
Do you know this browser?...
PH2150 Scientific Computing Skills
Introduction to Python programming
For -G7 programing language Teacher / Shamsa Hassan Alhassouni.
What Is a Program? A program is like an algorithm, but describes a process that is ready or can be made ready to run on a real computer Retrieved from:
Introduction to Python
Lecture 2 Python Programming & Data Types
Learning Outcomes –Lesson 4
Introduction to programming with Python
Lecture 2 Python Programming & Data Types
Introduction to Programming with Python
Topics Introduction to Value-returning Functions: Generating Random Numbers Writing Your Own Value-Returning Functions The math Module Storing Functions.
12th Computer Science – Unit 5
Introduction to Computer Science
Chapter 1: Programming Basics, Python History and Program Components
General Computer Science for Engineers CISC 106 Lecture 03
L L Line CSE 420 Computer Games Lecture #3 Introduction to Python.
EN Software Carpentry Python – A Crash Course Esoteric Sections Compiled Languages.
Python Basics. Topics Features How does Python work Basic Features I/O in Python Operators Control Statements Function/Scope of variables OOP Concepts.
Introduction to Computer Science
Introduction to Python
Programming for Business Computing Introduction
Presentation transcript:

Programming For Big Data Darren Redmond

Programming Languages Python R Java C, C++ Ruby

Why, Why, Why History of Python Why Python The End Game Guido van Rossum – 1989 was bored at Christmas Why Python Easy to learn Powerful Data structures Modular Embedding Map Reduce / Lambda / Yield Interactive Shell http://www.python-course.eu/index.php The End Game http://www.michael-noll.com/tutorials/writing-an-hadoop-mapreduce-program-in-python/

Interactive Interpreter python >>> print “Hello World” easier? “Hello World” 12 / 7 12.0 / 7 3 + 2 * 4 # 11 _ # the most recent value _ * 3 # 33 Ctrl-D

Execute Script Multiple ways to execute a script – below are 4 ways for a script called script-name.py: From command prompt - uncompiled python script-name.py From python interpreter – ensure to start python from directory of script for now. import py_compile py_compile.compile(‘script-name.py’) Compile from command line python –m py_compile script-name.py python –m compileall . Py and Pyc files available

Indentation Scope achieved through indentation – not brackets Auto creation and interpretation of variables i = 42 i = i + 1 # 43 print id(i) Types Numbers -> integers, long integers, floating point numbers, complex Strings -> functions – concat (+), slicing [2:4] Operators – input, raw_input Casting to list etc…

Conditional if elif else max = (a > b) ? a : b; This is an abbreviation for the following C code if (a > b) max=a; max=b; C programmers have to get used to a different notation in Python max = a if (a > b) else b;

Looping #!/usr/bin/env python n = 100 sum = 0 i = 1 while i <= n: sum = sum + i i = i + 1 print "Sum of 1 until %d: %d" % (n,sum)

Bibliography Python for Data Analysis Programming Python, 4th Edition Data Wrangling with Pandas, NumPy, and Ipython Wes McKinney, O’Reilly, 2012 Programming Python, 4th Edition Powerful Object-Oriented Programming Mark Lutz, O’Reilly, 2010 Agile Data Science – Building Data Analytics with Hadoop Russell Jurney, O’Reilly, 2013 Functional Python Programming Steven Lott, Pakt Publishing, 2015

Practice, Practice, Practice From Lecture 1 you should be able to write a python script file to do calculations and print them to the screen Write a program to print ‘Hello World’ to the screen Write a program to sum the first 100 numbers Write a program to multiply the first 10 numbers

Summary Programming Languages for Big Data Why Python Hello World Executing a Script Indentation Conditional Programming Looping Bibliography Practice