Page 546 - Python Data Science Handbook
P. 546

NumPy arrays: multidimensional subarrays,  fitting, 408-411
                    45                                 kernels and, 411-414
                  NumPy arrays: one-dimensional subarrays,  maximizing the margin, 407-416
                    44                                 motivating, 405-420
                  NumPy vs. Python, 46                 simple face detector, 507
                  Pandas conventions, 114              softening margins, 414-416
               sorting arrays, 85-92                 surface plots, three-dimensional, 293-298
                  along rows or columns, 87
                  basics, 85                         T
                  fast sorting with np.sort and np.argsort, 86  t-distributed stochastic neighbor embedding (t-
                  k-nearest neighbors example, 88-92   SNE), 456, 472
                  partitioning, 88                   tab completion
               source code, accessing, 5               exploring IPython modules with, 6-7
               splitting arrays, 49                    of object contents, 6
               string operations (see vectorized string opera‐  when importing, 7
                  tions)                             table, data as, 343
               structured arrays, 92-96              target array, 344-345
                  advanced compound types, 95        term frequency-inverse document frequency
                  creating, 94                         (TF-IDF), 378
                  record arrays, 96                  text, 377
               stylesheets                             (see also annotation of plots)
                  Bayesian Methods for Hackers, 288    transforms and position of, 270-272
                  default style, 286                 text entry shortcuts, 9
                  FiveThirtyEight style, 287         three-dimensional plotting
                  ggplot, 287                          contour plots, 292
                  Matplotlib, 285-290                  Möbius strip visualization, 296-298
                  Seaborn, 289                         points and lines, 291
               subarrays                               surface plots, 293-298
                  as no-copy views, 46                 surface triangulations, 295-298
                  creating copies, 46                  wireframes, 293
                  slicing multidimensional, 45         with Matplotlib, 290-298
                  slicing one-dimensional, 44        ticks (tick marks)
               subplots                                customizing, 275-282
                  manual customization, 263-264        fancy formats, 279-281
                  multiple, 262-268                    formatter/locator options, 281
                  plt.axes() for, 263-264              major and minor, 276
                  plt.GridSpec() for, 266-268          reducing/increasing number of, 278
                  plt.subplot() for, 264             Tikhonov regularization, 398
                  plt.subplots() for, 265            time series
               subsets, faceted histograms, 318        bar plots, 321
               suffixes keyword, 153                   dates and times in Pandas, 191
               supervised learning, 332                datetime64, 189
                  classification task, 333-335         frequency codes, 195
                  regression task, 335-338             indexing data by timestamps, 192
               support vector (defined), 409           native Python dates and times, 189
               support vector classifier, 408-411      offsets, 196
               support vector machines (SVMs), 405     Pandas, 188-209
                  advantages/disadvantages, 420        Pandas data structures for, 192-194
                  face recognition example, 416-420    pd.date_range(), 193



               528  |  Index
   541   542   543   544   545   546   547   548