Python for Data Science

  1. Numerical Computing with NumPy
    1. NumPy Fundamentals
      1. Introduction to NumPy
        1. NumPy's Role in Scientific Computing
          1. Performance Benefits
            1. Integration with Other Libraries
            2. The ndarray Object
              1. Array Concept
                1. Array Properties
                  1. shape Attribute
                    1. dtype Attribute
                      1. ndim Attribute
                        1. size Attribute
                          1. itemsize Attribute
                          2. Memory Layout
                            1. Contiguous Arrays
                              1. Strides
                                1. Views vs Copies
                              2. NumPy vs Python Lists
                                1. Performance Comparison
                                  1. Memory Efficiency
                                    1. Vectorization Benefits
                                      1. Type Homogeneity
                                    2. Array Creation and Initialization
                                      1. Creating Arrays from Existing Data
                                        1. From Python Lists
                                          1. From Tuples
                                            1. From Other Arrays
                                              1. array() Function Parameters
                                              2. Intrinsic Array Creation
                                                1. Zeros and Ones
                                                  1. zeros() Function
                                                    1. ones() Function
                                                      1. empty() Function
                                                        1. full() Function
                                                        2. Range-based Creation
                                                          1. arange() Function
                                                            1. linspace() Function
                                                              1. logspace() Function
                                                              2. Identity and Diagonal Arrays
                                                                1. eye() Function
                                                                  1. identity() Function
                                                                    1. diag() Function
                                                                  2. Random Array Generation
                                                                    1. Random Module Overview
                                                                      1. Random Number Generation
                                                                        1. rand() Function
                                                                          1. randn() Function
                                                                            1. randint() Function
                                                                              1. random() Function
                                                                              2. Random Sampling
                                                                                1. choice() Function
                                                                                  1. shuffle() Function
                                                                                  2. Random Seed Management
                                                                                    1. Reproducible Results
                                                                                      1. seed() Function
                                                                                    2. Array Data Types
                                                                                      1. NumPy Data Types
                                                                                        1. Integer Types
                                                                                          1. Float Types
                                                                                            1. Complex Types
                                                                                              1. Boolean Type
                                                                                                1. String Types
                                                                                                2. Data Type Specification
                                                                                                  1. dtype Parameter
                                                                                                    1. Type Conversion
                                                                                                      1. astype() Method
                                                                                                  2. Array Indexing and Selection
                                                                                                    1. Basic Indexing
                                                                                                      1. Single Element Access
                                                                                                        1. One-Dimensional Indexing
                                                                                                          1. Multi-Dimensional Indexing
                                                                                                            1. Row and Column Selection
                                                                                                              1. Element Access in 2D Arrays
                                                                                                              2. Negative Indexing
                                                                                                              3. Array Slicing
                                                                                                                1. One-Dimensional Slicing
                                                                                                                  1. Multi-Dimensional Slicing
                                                                                                                    1. Row Slicing
                                                                                                                      1. Column Slicing
                                                                                                                        1. Combined Slicing
                                                                                                                        2. Step Parameter in Slicing
                                                                                                                          1. Slice Assignment
                                                                                                                          2. Advanced Indexing
                                                                                                                            1. Boolean Indexing
                                                                                                                              1. Creating Boolean Masks
                                                                                                                                1. Conditional Selection
                                                                                                                                  1. Multiple Conditions
                                                                                                                                    1. Boolean Array Operations
                                                                                                                                    2. Fancy Indexing
                                                                                                                                      1. Integer Array Indexing
                                                                                                                                        1. Multi-Dimensional Fancy Indexing
                                                                                                                                          1. Combining Boolean and Fancy Indexing
                                                                                                                                        2. Array Views and Copies
                                                                                                                                          1. Understanding Views
                                                                                                                                            1. Creating Copies
                                                                                                                                              1. copy() Method
                                                                                                                                                1. Memory Implications
                                                                                                                                              2. Array Operations and Computation
                                                                                                                                                1. Universal Functions (ufuncs)
                                                                                                                                                  1. Element-wise Operations
                                                                                                                                                    1. Vectorization Concept
                                                                                                                                                      1. Broadcasting Rules
                                                                                                                                                        1. ufunc Methods
                                                                                                                                                          1. reduce()
                                                                                                                                                            1. accumulate()
                                                                                                                                                              1. outer()
                                                                                                                                                            2. Arithmetic Operations
                                                                                                                                                              1. Basic Arithmetic
                                                                                                                                                                1. Addition and Subtraction
                                                                                                                                                                  1. Multiplication and Division
                                                                                                                                                                    1. Power and Modulo
                                                                                                                                                                    2. Array-Scalar Operations
                                                                                                                                                                      1. Array-Array Operations
                                                                                                                                                                        1. In-place Operations
                                                                                                                                                                        2. Mathematical Functions
                                                                                                                                                                          1. Trigonometric Functions
                                                                                                                                                                            1. sin(), cos(), tan()
                                                                                                                                                                              1. Inverse Trigonometric Functions
                                                                                                                                                                              2. Exponential and Logarithmic
                                                                                                                                                                                1. exp(), log(), log10()
                                                                                                                                                                                  1. Power Functions
                                                                                                                                                                                  2. Rounding Functions
                                                                                                                                                                                    1. round(), floor(), ceil()
                                                                                                                                                                                      1. Truncation Functions
                                                                                                                                                                                    2. Comparison Operations
                                                                                                                                                                                      1. Element-wise Comparisons
                                                                                                                                                                                        1. Logical Operations
                                                                                                                                                                                          1. logical_and()
                                                                                                                                                                                            1. logical_or()
                                                                                                                                                                                              1. logical_not()
                                                                                                                                                                                              2. Array Equality
                                                                                                                                                                                                1. allclose() Function
                                                                                                                                                                                                  1. array_equal() Function
                                                                                                                                                                                                2. Aggregation Functions
                                                                                                                                                                                                  1. Statistical Functions
                                                                                                                                                                                                    1. sum() and nansum()
                                                                                                                                                                                                      1. mean() and nanmean()
                                                                                                                                                                                                        1. std() and var()
                                                                                                                                                                                                          1. min() and max()
                                                                                                                                                                                                            1. median() and percentile()
                                                                                                                                                                                                            2. Axis Parameter
                                                                                                                                                                                                              1. Aggregation Along Axes
                                                                                                                                                                                                                1. Keepdims Parameter
                                                                                                                                                                                                                2. Conditional Aggregations
                                                                                                                                                                                                                  1. where() Function
                                                                                                                                                                                                                    1. Masked Arrays
                                                                                                                                                                                                                3. Array Manipulation and Reshaping
                                                                                                                                                                                                                  1. Shape Manipulation
                                                                                                                                                                                                                    1. Reshaping Arrays
                                                                                                                                                                                                                      1. reshape() Method
                                                                                                                                                                                                                        1. Reshape Parameters
                                                                                                                                                                                                                          1. Automatic Dimension Calculation
                                                                                                                                                                                                                          2. Flattening Arrays
                                                                                                                                                                                                                            1. flatten() Method
                                                                                                                                                                                                                              1. ravel() Function
                                                                                                                                                                                                                                1. Differences and Use Cases
                                                                                                                                                                                                                                2. Transposition
                                                                                                                                                                                                                                  1. transpose() Method
                                                                                                                                                                                                                                    1. T Attribute
                                                                                                                                                                                                                                      1. Multi-dimensional Transposition
                                                                                                                                                                                                                                    2. Array Combination
                                                                                                                                                                                                                                      1. Stacking Arrays
                                                                                                                                                                                                                                        1. Vertical Stacking (vstack)
                                                                                                                                                                                                                                          1. Horizontal Stacking (hstack)
                                                                                                                                                                                                                                            1. Depth Stacking (dstack)
                                                                                                                                                                                                                                              1. General Stacking (stack)
                                                                                                                                                                                                                                              2. Concatenation
                                                                                                                                                                                                                                                1. concatenate() Function
                                                                                                                                                                                                                                                  1. Axis Parameter
                                                                                                                                                                                                                                                    1. Multiple Array Concatenation
                                                                                                                                                                                                                                                  2. Array Splitting
                                                                                                                                                                                                                                                    1. Splitting Functions
                                                                                                                                                                                                                                                      1. split() Function
                                                                                                                                                                                                                                                        1. vsplit() Function
                                                                                                                                                                                                                                                          1. hsplit() Function
                                                                                                                                                                                                                                                            1. dsplit() Function
                                                                                                                                                                                                                                                            2. Array Sections
                                                                                                                                                                                                                                                              1. Equal vs Unequal Splits
                                                                                                                                                                                                                                                                1. Split Indices
                                                                                                                                                                                                                                                              2. Array Repetition
                                                                                                                                                                                                                                                                1. repeat() Function
                                                                                                                                                                                                                                                                  1. tile() Function
                                                                                                                                                                                                                                                                    1. Broadcasting for Repetition
                                                                                                                                                                                                                                                                  2. Linear Algebra Operations
                                                                                                                                                                                                                                                                    1. Matrix Operations
                                                                                                                                                                                                                                                                      1. Matrix Multiplication
                                                                                                                                                                                                                                                                        1. dot() Function
                                                                                                                                                                                                                                                                          1. matmul() Operator (@)
                                                                                                                                                                                                                                                                            1. Differences and Use Cases
                                                                                                                                                                                                                                                                            2. Matrix Properties
                                                                                                                                                                                                                                                                              1. Transpose Operations
                                                                                                                                                                                                                                                                                1. Matrix Trace
                                                                                                                                                                                                                                                                                  1. Matrix Rank
                                                                                                                                                                                                                                                                                2. Linear Algebra Functions
                                                                                                                                                                                                                                                                                  1. Matrix Decomposition
                                                                                                                                                                                                                                                                                    1. Eigenvalues and Eigenvectors
                                                                                                                                                                                                                                                                                      1. Singular Value Decomposition
                                                                                                                                                                                                                                                                                        1. QR Decomposition
                                                                                                                                                                                                                                                                                          1. Cholesky Decomposition
                                                                                                                                                                                                                                                                                          2. Matrix Inverse and Determinant
                                                                                                                                                                                                                                                                                            1. inv() Function
                                                                                                                                                                                                                                                                                              1. det() Function
                                                                                                                                                                                                                                                                                                1. Pseudo-inverse
                                                                                                                                                                                                                                                                                                2. Solving Linear Systems
                                                                                                                                                                                                                                                                                                  1. solve() Function
                                                                                                                                                                                                                                                                                                    1. Least Squares Solutions
                                                                                                                                                                                                                                                                                                  2. Vector Operations
                                                                                                                                                                                                                                                                                                    1. Vector Norms
                                                                                                                                                                                                                                                                                                      1. Dot Products
                                                                                                                                                                                                                                                                                                        1. Cross Products
                                                                                                                                                                                                                                                                                                          1. Vector Projections