BigData-python

  1. How are operators applied?
    Operators are applied left to right, except for exponentation

    Image Upload 2
  2. How do you write new line/enter in a string?
    \n

    Image Upload 4
  3. How is a list denoted and is it mutable or immutable?
    • [1,2,3]
    • mutable, it can be changed
  4. How is a tuple denoted, and is it mutable or immutable?
    • (1,2,3)
    • immutable, can not edit
  5. Is the y a copy or a reference of x?
    Image Upload 6
    A reference. It will always represent what x is, even if x is later changed

    • Image Upload 8
    • Image Upload 10
  6. Is the y a copy or a reference of x?
    Image Upload 12
    • Y is a copy of x
    • Image Upload 14
  7. What are two ways to continue long lines of code (moving it to cover multiple lines, instead of one long line)?
    Image Upload 16
  8. What are two major ways to do an operation on a variable/object?
    • Image Upload 18
    • *for the methods, .pop modifies the original list and popped something out
  9. Markdown syntax for:
    plain text
    new line
    new paragraph
    italics
    bold
    strikethrough
    Image Upload 20
  10. How would you indicate bold and italics in markdown?
    *_ _ bolditalics _ _ * = bolditalics
  11. How do you create table of contents sort of headers in markdown?
    Image Upload 22
  12. How do you create a reference link in markdown?
    Image Upload 24
  13. How would you create a general link in markdown?
    Image Upload 26
  14. How would you link an image in markdown?
    Image Upload 28
  15. What is a module?
    A collection of (related) definitions and statements that are grouped together in a single file (a .py file)
  16. Why is important to set a seed when using the import module?
    Image Upload 30
    Anytime you are dealing with random number generation, we are not truly getting random numbers out. There is an algorithm underneath creating the values, so at any specific starting point the algorithm will always produce the same values. You get more pseudo-randomness by setting the seed.
  17. In longform data, what are rows and columns otherwise known as?
    • rows= observations
    • columns= variables
    • Image Upload 32
  18. What are the four major goals when using data?
    • 1) Description
    • 2) Inference
    • 3) Prediction/Classification
    • 4) Pattern finding
  19. What is supervised learning?
    • A variable (or variables) represents an output or response of
    • interest:
    • Image Upload 34
  20. What is statistical learning?
    Inference, prediction/classification, and pattern finding. Classified into two groups: supervised learning and unsupervised learning
  21. What is unsupervised learning?
    • There is no end-goal
    • Image Upload 36
  22. What are ways to handle errors in code?
    Try/Except
  23. How do you create your own method to handle errors in code?
    • Raise Exception
    • Image Upload 38
Author
saucyocelot
ID
360425
Card Set
BigData-python
Description
Week 2-3: steps for coding in python
Updated