Code Monkey home page Code Monkey logo

dsc-1-06-02-introduction-summary-online-ds-sp-000's Introduction

Introduction

Introduction

This lesson summarizes the topics we'll be covering in section 06 and why they'll be important to you as a data scientist.

Objectives

You will be able to:

  • Understand and explain what is covered in this section
  • Understand and explain why the section will help you to become a data scientist

All About Objects

From the start of this course, you've been surrounded by objects and "Object Oriented Programming" (OOP)! In an earlier lesson, we talked very briefly about objects in Python when we introduced built in functions and methods, and many times when you use a data science library, you'll find that it was written and should be used in an "Object Oriented" way.

While it may not seem immediately applicable to predicting values or categories or creating clusters, a strong foundation in OOP will put you in a much better position to use and write code in a way that'll be easy to read, use and test, so please work your way through this content carefully. The concepts introduced will continue to be of value to you throughout your data science career!

An Introduction to OO

We start with a brief intorduction to Object Oriented Programming.

Classes and Instances

We then dig into the difference between classes (a kind of thing) and instances (a particular thing). We might have a Person class which identifies the behaviors of people in general, but we create (instantiate) an instance of the class for a particular person - Ann or Fred or Bill.

Instance Methods, Instance Variables & Self

From there we dig into instance methods which are actions (methods) you can call on a particular object (e.g. bill.speak()) and variables (like bill.age to see how old he is). We also dig into the principle of "self" in OO Python.

Getters and Setters

Finally, we learn about and practice the use of methods for accessing instance variables to improve the robustness and flexibility of our code.

Summary

In this section, we'll start to provide you with a solid introduction to Object Oriented Programming which you will find useful whenever you're writing code.

dsc-1-06-02-introduction-summary-online-ds-sp-000's People

Contributors

peterbell avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.