Download>Subject> AI Artificial Intelligence Development Basics: Python Library

AI Artificial Intelligence Development Basics: Python Library

Python拥有丰富的类库,为数据科学、机器学习和自然语言处理等领域提供了强大的支持,显著降低了人工智能开发人员的工作难度。

本文集收集整理了一些重要的Python 类库学习资源,包括:NumPy、SciPy、Pandas、Matplotlib、Seaborn。希望对大家有所帮助。

AI Artificial Intelligence Development Basics: Python Library Document List

pdf
Python Data Science Cookbook
Points it Requires : 1 Type:Technical DocumentationUploader:太白金星Date:2021-05-30
Introduction:This book is a reference book for science, research, and computational and statistical methods centered on the deep needs of data. This book has five chapters, each of which introduces one or two key toolkits for Python data science. It starts with IPython and Jupyter, which provide the computing environment needed by data scientists; Chapter 2 explains NumPy, which provides ndarray objects, which can be used to efficiently store and manipulate large arrays in Python; Chapter 3 focuses on Pandas, which provides DataFrame objects, which can be used to efficiently store and manipulate labeled/column data in Python; Chapter 4 is the protagonist of Matplotlib, which provides many data visualization functions for Python; Chapter 5 focuses on Scikit-Learn, a library that provides efficient and clean Python implementations of the most important machine learning algorithms. This book is suitable for data science researchers who have a programming background and intend to use open source Python tools as tools for analyzing, manipulating, visualizing, and learning data.
pdf
Python Scientific Computing_Zhang Ruoyu
Points it Requires : 2 Type:Application DocumentsUploader:走马观花Date:2024-01-29
Introduction:Author: Zhang Ruoyu Publication Year: 2012 This book introduces how to develop scientific computing applications with Python. In addition to numerical calculations, it also focuses on how to make interactive 2D and 3D images, how to design sophisticated program interfaces, how to combine with high-speed computing programs written in C language, and how to write sound and image processing algorithms. The Python extension libraries involved in the book include NumPy, SciPy, SymPy, matplotlib, Traits, TraitsUI, Chaco, TVTK, Mayavi, VPython, OpenCV, etc. The application areas involved include numerical calculations, symbolic calculations, 2D charts, 3D data visualization, 3D animation demonstrations, image processing, and interface design. The book uses a large number of examples to guide readers to learn in depth step by step. Each example program has a detailed explanation and can run normally in the operating environment recommended by this book. In addition, this book is accompanied by a large number of charts and illustrations, striving to reduce long theoretical introductions and formula derivations so that readers can learn and master theoretical knowledge through examples and data.
pdf
Python Data Analysis Basic Tutorial: NumPy Learning Guide (2nd Edition)
Points it Requires : 1 Type:Technical DocumentationUploader:太白金星Date:2021-05-30
Introduction:NumPy is an excellent scientific computing library that provides many practical mathematical functions, powerful multidimensional array objects, and excellent computing performance. It can not only replace many functions of Matlab and Mathematica, but also has become an important part of the Python scientific computing ecosystem. But unlike these commercial products, it is free and open source software. This book starts with NumPy installation and gradually transitions to array objects, common functions, matrix operations, linear algebra, financial functions, window functions, quality control, etc., and is committed to comprehensively explaining NumPy and its use to beginner and intermediate Python programmers. In addition, through the rich examples in the book, you will also learn Matplotlib drawing and combine it with other Python scientific computing libraries (such as SciPy and Scikits) to make your work more effective and make your code more concise and efficient. Main content: Install NumPy on different platforms; Use concise and efficient NumPy code to achieve high-performance computing; Use powerful general functions; Use NumPy arrays and matrices; Use NumPy modules to easily perform complex numerical calculations; Matplotlib drawing; NumPy code testing.
pdf
Best Practices for Scientific Computing with Python: A Guide to SciPy
Points it Requires : 1 Type:Technical DocumentationUploader:抛砖引玉Date:2023-07-30
Introduction:This book aims to introduce the open source Python algorithm library and mathematical toolkit SciPy. In recent years, a complete ecosystem based on NumPy and SciPy has developed rapidly and has been widely used in many disciplines such as astronomy, biology, meteorology and climate science, and materials science. This book combines a large number of code examples to fully demonstrate the powerful scientific computing capabilities of SciPy, including quantile normalization with NumPy and SciPy, image region network with ndimage, frequency and fast Fourier transform, contingency table with sparse coordinate matrix, linear algebra in SciPy, function optimization in SciPy, etc. Preface ix Chapter 1. Elegant NumPy: Python for Scientific Applications 1 1.1 Introduction to Data: What is Gene Expression 2 1.2 NumPy N-dimensional Arrays 6 1.2.1 Why Use N-dimensional Arrays Instead of Python Lists 7 1.2.2 Vectorization 9 1.2.3 Broadcasting 9 1.3 Exploring Gene Expression Datasets 10 1.4 Normalization 13 1.4.1 Normalization Across Samples 13 1.4.2 Normalization Across Genes 19 1.4.3 Normalization Between Samples and Genes: RPKM 21 1.5 Summary 27 Chapter 2. Quantile Normalization with NumPy and SciPy 28 2.1 Getting the Data 30 2.2 Gene Expression Distribution Differences Between Independent Samples 30 2.3 Bidirectional Clustering of Count Data 33 2.4 Visualizing Clusters 35 2.5 Predicting Survivors 37 2.5.1 Further Work: Using TCGA Patient Clusters 41 2.5.2 3.1 Images are just NumPy arrays 43 3.2 Filters in signal processing 48 3.3 Image filtering (two-dimensional filters) 53 3.4 General filters: arbitrary functions of neighboring values ​​55 3.4.1 Exercise: Conway’s Game of Life 56 3.4.2 Exercise: Sobel gradient magnitude 56 3.5 Graphs and the NetworkX library 57 3.6 Region adjacency graphs 60 3.7 Elegant ndimage: How to create graph objects from image regions 63 3.8 Summary: Average color segmentation 65 Chapter 4 Frequency and the Fast Fourier Transform 67 4.1 Introducing frequency 67 4.2 Example: Birdsong spectrogram 69 4.3 History 74 4.4 Implementation 75 4.5 Choosing the length of the discrete Fourier transform 75 4.6 More discrete Fourier transform concepts 77 4.6.1 Frequencies and their ordering 77 4.6.2 Windowing 83 4.7 Practical application: Analyzing radar data 86 4.7.1 Signal properties in the frequency domain 91 4.7.2 After windowing 93 4.7.3 Radar images 95 4.7.4 Further applications of the fast Fourier transform 99 4.7.5 Further reading 99 4.7.6 Exercise: Image convolution 100 Chapter 5 Contingency tables with sparse coordinate matrices 101 5.1 Contingency tables 102 5.1.1 Exercise: Computational complexity of the confusion matrix 103 5.1.2 Exercise: Another way to calculate the confusion matrix 103 5.1.3 Exercise: Multiclass confusion matrix 104 5.2 scipy.sparse data format 104 5.2.1 COO format 104 5.2.2 Exercise: COO representation 105 5.2.3 5.5 Contingency Tables for Image Segmentation 113 5.6 Introduction to Information Theory 114 5.7 Information Theory for Image Segmentation: Information Variation 117 5.8 Converting NumPy Array Code to Use Sparse Matrices 119 5.9 Using Information Variation 120 Chapter 6 Linear Algebra in SciPy 128 6.1 Linear Algebra Basics 128 6.2 Laplacian Matrices for Graphs 129 6.3 Laplacian Matrices for Brain Data 134 6.3.1 Exercise: Displaying Neighbor Views 138 6.3.2 Exercise Challenge: Sparse Matrix Linear Algebra 138 6.4 PageRank: Linear Algebra for Prestige and Importance 139 6.4.1 Exercise: Dealing with Hanging Nodes 144 6.4.2 Exercise: Equivalence of Different Eigenvector Methods 144 6.5 Conclusion 144 Chapter 7 Function Optimization in SciPy 145 7.1 SciPy Optimization Module: sicpy.optimize 146 7.2 Image Registration with optimize 152 7.3 Avoiding Local Minima with Basin Hopping 155 7.4 Choosing the Right Objective Function 156 Chapter 8 Playing with Big Data on Laptops with Toolz 163 8.1 Stream Processing with yield 164 8.2 Introducing the Toolz Stream Library 167 8.3 k-mer Counting and Error Correction 169 8.4 Currying: The Spice of Streams 173 8.5 Back to k-mer Counting 175 8.6 Genome-wide Markov Models 177 Postscript 182 Answers to Appendix Exercises 186 About the Author 206 Cover Description 206
pdf
Pandas: Data Processing and Analysis with Python
Points it Requires : 1 Type:Technical DocumentationUploader:抛砖引玉Date:2023-05-21
Introduction:If you want to give full play to the powerful role of Python, if you want to be a good Python engineer, you should first learn Pandas. This is a book that comprehensively covers the common needs and pain points of Pandas users. Based on the principles of practicality and ease of learning, it provides a comprehensive and detailed explanation of Pandas from multiple dimensions such as functions, usage, and principles. It is not only a rare introductory book for beginners to systematically learn Pandas, but also an indispensable query manual for experienced Python engineers. This book has 17 chapters and is divided into seven parts. Part I (Chapters 1-2) Introduction to Pandas First introduces the functions, usage scenarios and learning methods of Pandas, then explains in detail the construction of the Python development environment, and finally introduces a large number of basic functions of Pandas, aiming to guide readers to get started quickly. Part II (Chapters 3-5) Basics of Pandas Data Analysis Details Pandas reading and outputting data, index operations, data type conversion, query screening, statistical calculations, sorting, displacement, data modification, data iteration, function application and other contents. Part III (Chapters 6-9) Data Form Changes explains Pandas\' grouping and aggregation operations, merging operations, comparison operations, data pivoting, transposition, normalization, standardization, etc., as well as how to use multi-layer indexes to increase or decrease the dimension of data. Part IV (Chapters 10-12) Data Cleaning explains the identification, deletion, and filling of missing and duplicate values, data replacement, format conversion, text extraction, connection, matching, segmentation, replacement, formatting, virtual variableization, etc., as well as the application scenarios and operation methods of classified data. Part V (Chapters 13-14) Time Series Data Analysis explains the processing and analysis of various time type data in Pandas, as well as the window calculations often used in time series data processing. Part VI (Chapters 15-16) Visualization explains how Pandas\' style function makes data tables more expressive, and how Pandas\' drawing function lets the data speak for itself. Part 7 (Chapter 17) practical cases introduce the thinking process from requirements to code, how to use chain programming ideas to improve the efficiency of code writing and data analysis, as well as the basic methods of data analysis and the data analysis tools and technology stacks that need to be mastered. In addition, a large number of application cases and detailed code explanations are given from the two perspectives of data processing and data analysis. Preface Part I Getting Started with Pandas Chapter 1 Introduction to Pandas and Quick Start 1.1 What is Pandas 1.1.1 Introduction to Python 1.1.2 Applications of Python 1.1.3 Why not choose R 1.1.4 Introduction to Pandas 1.1.5 People who use Pandas 1.1.6 Basic functions of Pandas 1.1.7 How to learn Pandas 1.1.8 Summary 1.2 Environment Setup and Installation 1.2.1 Python Environment Installation 1.2.2 Introduction to Anaconda 1.2.3 Installing miniconda 1.2.4 Multiple Python Version Environments 1.2.5 Installing an Editor 1.2.6 Jupyter Notebook 1.2.7 Installing a Third-Party Library with pip 1.2.8 Installing Jupyter Notebook 1.2.9 Starting Jupyter Notebook 1.2.10 Using Jupyter Notebook 1.2.11 Installing Pandas 1.2.12 Summary 1.3 Quick Start with Pandas 1.3.1 Installation and import1.3.2 Prepare data set1.3.3 Read data1.3.4 View data1.3.5 Verify data1.3.6 Create index1.3.7 Data selection1.3.8 Sorting1.3.9 Grouping and aggregation1.3.10 Data conversion1.3.11 Add columns1.3.12 Statistical analysis1.3.13 Drawing1.3.14 Export1.3.15 Summary1.4 Summary of this chapterChapter 2 Data structure2.1 Overview of data structure2.1.1 What is data2.1.2 What is data structure2.1.3 Summary2.2 Python data structure2.2.1 Numbers2.2.2 Strings2.2.3 Boolean2.2.4 Lists2.2.5 Tuples…Part 2 Basics of Pandas data analysisPart 3 Changes in data formPart 4 Data cleaningPart 5 Time series data analysisPart 6 VisualizationPart 7 Actual combat cases
pdf
Python Scientific Computing and Data Analysis
Points it Requires : 1 Type:Technical DocumentationUploader:太白金星Date:2021-05-30
Introduction:This book takes readers through all aspects of NumPy, the most popular scientific computing library. The book not only introduces the installation, use and various related concepts of NumPy, but also introduces how to use this latest open source software library to write readable, efficient and fast code in a way that is as close to traditional mathematical language as possible. Finally, it explores several scientific computing projects related to NumPy. In addition, this book will lay a solid foundation for you to master NumPy arrays and general functions, and will also teach you to use Matplotlib for drawing through examples and understand projects related to SciPy. This book will help you: • Learn advanced indexing techniques and linear algebra knowledge • Understand the adjustment of array shape and image size • Explore broadcasting mechanisms and histograms • Analyze NumPy code and present the analysis results in a visual way • Use Cython to speed up the code • Use array interfaces to share data • Use general functions and interoperability functions • Learn Matplotlib and SciPy, which are often used with NumPy
pdf
Python Data Visualization Matplotlib Practice (Liu Dacheng)
Points it Requires : 1 Type:Technical DocumentationUploader:抛砖引玉Date:2023-05-24
Introduction:This book uses Matplotlib to explain the key knowledge and skills needed to practice Python data visualization. This book is mainly composed of four parts: Matplotlib Introduction, Advanced, Practice, and Extension. At the same time, in order to facilitate readers to effectively practice the contents of the book, relevant chapters will be accompanied by a large number of typical comprehensive cases. The codes used in the book are all basic content in Python programming knowledge, which is conducive to readers to focus their time and energy on the practice of data visualization itself. Therefore, this book is suitable for people of insight in various industries and fields who are interested in Python data visualization. Part 1 Getting Started Chapter 1 Use functions to draw matplotlib chart elements 2 1.1 The main functions for drawing matplotlib chart elements 2 1.2 Prepare data 3 1.3 Use functions to draw matplotlib chart elements 4 1.3.1 Function plot() - Show the trend of variables 4 1.3.2 Function scatter() - Find the relationship between variables 5 1.3.3 Function xlim() - Set the numerical display range of the x-axis 6 1.3.4 Function xlabel() - Set the label text of the x-axis 7 1.3.5 Function grid() - Draw grid lines for scale lines 8 1.3.6 Function axhline() - Draw horizontal reference lines parallel to the x-axis 9 1.3.7 Function axvspan() - Draw reference areas perpendicular to the x-axis 11 1.3.8 Function annotate() - Add directional annotation text for graphic content details 12 1.3.9 Function text() - Add non-directional annotation text for graphic content details 13 1.3.10 Function title()——Add a title to the graphic content15 1.3.11 Function legend()——Text label legend for different graphics16 1.4 Function combination application17 Chapter 2 Using statistical functions to draw simple graphics20 2.1 Function bar()——Draw a bar chart20 2.2 Function barh()——Draw a bar chart22 2.3 Function hist()——Draw a histogram23 2.4 Function pie()——Draw a pie chart25 2.5 Function polar()——Draw a polar line chart26 2.6 Function scatter()——Draw a bubble chart27 2.7 Function stem()——Draw a cotton swab chart29 2.8 Function boxplot()——Draw a box plot30 2.9 Function errorbar()——Draw an error bar chart31 Chapter 3 Drawing statistical graphics33 3.1 Bar chart33 3.1.1 3.1.2 Drawing principle 3.1.3 Bar chart 3.2 Bar chart 3.3 Stacked chart 3.4 Block chart 3.5 Parameter exploration 3.6 Stacked line chart, intermittent bar chart and step chart 3.6.1 Using stackplot() to draw a stacked line chart 3.6.2 Using broken_bar() to draw a step chart 3.7 Histogram 3.7.1 Application scenario - Distribution display of quantitative data 3.7.2 Drawing principle 3.7.3 3.7.4 Stacked Histogram 51 3.7.5 Different Shapes of Histogram 53 3.8 Pie Chart 55 3.8.1 Application Scenario - Proportional Display of Qualitative Data 55 3.8.2 Drawing Principle 55 3.8.3 Further Reading - Non-Split Pie Chart 57 3.8.4 Example - Drawing Embedded Ring Pie Chart 58 3.9 Box Plot 60 3.9.1 Application Scenario - Distribution Comparison of Multiple Groups of Quantitative Data 60 3.9.2 Drawing Principle 61 3.9.3 Further Reading - Meaning and Calculation Method of Box, Whiskers and Outliers 63 3.9.4 Example 1 - Horizontal Box Plot 65 3.9.5 Example 2 - Horizontally Placed Box Plot Without Drawing Outliers 66 3.10 Error Bar Plot 67 3.10.1 Application Scenario - Error Range of Quantitative Data 67 3.10.2 Drawing Principles 68 3.10.3 Example 1 - Histogram with Error Bars 69 3.10.4 Example 2 - Bar Chart with Error Bars 71 3.10.5 Example 3 - Parallel Histograms of Multiple Data with Error Bars 72 3.10.6 Example 4 - Stacked Histograms with Error Bars 74 Chapter 4 Improving Statistical Graphics 77 4.1 Adding Legends and Titles 77 4.1.1 How to Set Legends and Titles 77 4.1.2 Example 1 - Adjusting the Display Style of Legends 79 4.1.3 Example 2 - Adjusting the Display Style of Titles 80 4.1.4 Example 3 - Pie Chart with Legend 82 4.2 Adjusting the Scale Range and Scale Labels 83 4.2.1 How to Adjust the Scale Range and Scale Labels 84 4.2.2 Further Reading - Function subplot() 85 4.2.3 4.3 Adding Tables to Statistical Graphics 87 Part 2: Advanced Chapter 5: Advanced Statistical Graphics Drawing: Graphic Style 92 5.1 Setting the Scale Style of the Axis 92 5.1.1 How to Use the Scale Locator and Scale Formatter 92 5.1.2 Calling Functions in the pyplot Module to Set the Scale Style 95 5.1.3 Example 1: Customization of Scale Labels and Tick Mark Styles 95 5.1.4 Example 2: Currency and Time Series Scale Labels 96 5.2 Adding Indicator Annotations and Non-Indicator Annotations 98 5.2.1 How to Add Indicator Annotations and Non-Indicator Annotations 98 5.2.2 Example 1: Setting a Rounded Text Box 100 5.2.3 Example 2: Watermark Effect for Text 101 5.2.4 Example 3: Annotations with Arc Indications in Rounded Frames 102 5.2.5 5.3.1 How to implement the projection effect for titles and axis labels 107 5.3.2 Example - Add a text box to the axis label 109 Chapter 6 Main functions for dividing the canvas 111 6.1 Function subplot(): Draw sub-areas with the same geometric shape in the grid area 111 6.1.1 How to use the function subplot() 112 6.1.2 Example 1 - Draw a line chart on a polar coordinate axis 113 6.1.3 Example 2 - Draw a scatter plot on a polar coordinate axis 114 6.1.4 Example 3 - Implementing graphic display on the drawing area of ​​a non-equally divided canvas 115 6.2 Function subplot2grid(): Let the sub-areas span a fixed grid layout 116 6.2.1 6.2.2 Extended reading - How to use the GridSpec class in the gridspec module 118 6.3 Function subplots(): Create a drawing mode with multiple subareas on a canvas 120 6.3.1 Case 1 - Create a drawing mode with a canvas and a subarea 120 6.3.2 Case 2 - Create a drawing mode with a canvas and two subareas 122 6.3.3 Case 3 - Combined display of multiple statistical graphics 124 Chapter 7 Shared axes of drawing areas 128 7.1 Shared axes of a single drawing area 128 7.2 Shared axes of different subareas 130 7.2.1 Setting method 130 7.2.2 Case - Remove the gaps between subareas of shared axes 135 7.3 Shared axes of individual subareas 136 7.3.1 Setting method 136 7.3.2 Further reading - Use the autoscale() function to adjust the axis range 138 Part 3 Exercise Chapter 8 Advanced Applications of Axis 142 8.1 Setting the Position and Display of Axis 142 8.1.1 Case 1 - Adding any number of axes to any position in the canvas 142 8.1.2 Case 2 - Adjusting the display, hiding and scale range of the determined axes 144 8.1.3 Further reading - Using the axis() function to draw axes 145 8.2 Using two methods to control the display of axis scales 146 8.2.1 Method 1 - Calling the Axes.set_xticks() and Axes.set_yticks() instance methods 146 8.2.2 Method 2 - Calling the setp() function 147 8.2.3 Case 1 - Customized display of cotton swab charts 149 8.2.4 Case 2 - Customized display of axis style and position 150 8.3 Controlling the display of axes 152 8.4 Moving the position of axes 154 Chapter 9 Setting the display style of line types and marker types 158 9.1 9.1.1 Method 1 - Setting the keyword parameter in the call signature in the form of \"fontdict=font\" 158 9.1.2 Method 2 - Setting the keyword parameter in the form of \"**font\" 160 9.2 Setting the display style of the line type 161 9.3 Setting the display style of the marker type 162 9.3.1 Method 1 - Single character mode 162 9.3.2 Method 2 - mathtext mode 164 9.4 Further reading 166 9.4.1 Example 1 - Setting different display forms of the \"dash\" line style 166 9.4.2 Example 2 - Setting the marker fill style 168 9.4.3 Example 3 - Setting the call signature of the function plot() 170 Part 4 Extension Chapter 10 Matplotlib configuration 174 10.1 Modify the configuration of matplotlib at the code level 174 10.1.1 175 10.1.2 Method 2 - Calling the attribute dictionary matplotlib.rcParams 175 10.2 Modifying the matplotlib configuration at the project level 176 10.2.1 Configuration file location path 176 10.2.2 Setting method 177 Chapter 11 Text attribute setting 179 11.1 Setting font attributes and text attributes 179 11.1.1 Method 1 - Changing the font attribute values ​​and text attribute values ​​of the configuration file matplotlibrc 181 11.1.2 Method 2 - Adjusting the font attribute values ​​and text attribute values ​​through the attribute dictionary rcParams 182 11.1.3 Method 3 - By setting the keyword parameters of the function 183 11.2 Further reading - Manually adding fonts 184 11.3 Example - Visual display of the main attributes of fonts 185 Chapter 12 Color usage 188 12.1 Using color parameters and color mapping tables 188 12.1.1 Using Color Parameters 188 12.1.2 Using Color Mapping Tables 190 12.2 Comprehensive Examples 193 12.2.1 Example 1 - Color Usage Mode for Simulation Graphs 193 12.2.2 Example 2 - Color Usage Mode for Scatter Graphs 194 12.2.3 Example 3 - Color Usage Mode for Polar Region Graphs 195 12.2.4 Example 4 - Color Usage Mode for Contour Graphs 197 12.2.5 Example 5 - Color Usage Mode for Color Scales 198 Chapter 13 Displaying and Saving Output Graphics 200 13.1 Running Command Lines to Display Output Graphics 200 13.1.1 Method 1 - Python Shell Mode 200 13.1.2 Method 2 - IPython Shell Mode 203 13.2 Saving Output Graphics 205 13.2.1 Method 1 - Using the \"Save\" Button to Store 205 13.2.2 Method 2 - Saving by executing code statements 207 Appendix A Python basics 208 Appendix B NumPy basics 213 Appendix C How to install matplotlib, NumPy, and IPython 2172 Method 2 - Saving by executing code statements 207 Appendix A Python basics 208 Appendix B NumPy basics 213 Appendix C How to install matplotlib, NumPy, and IPython 2172 Method 2 - Saving by executing code statements 207 Appendix A Python basics 208 Appendix B NumPy basics 213 Appendix C How to install matplotlib, NumPy, and IPython 217
pdf
Python data visualization matplotlib advanced
Points it Requires : 1 Type:Technical DocumentationUploader:抛砖引玉Date:2023-05-24
Introduction:\"Python Data Visualization: Matplotlib Practice\" uses a large number of matplotlib practical cases to explain the implementation methods of Python data visualization in various application directions. By studying these practical cases, readers can better master the advanced skills of Python data visualization. This book is mainly composed of 5 parts: graphics, elements, interaction, exploration, and expansion. The practical cases in each part are conducive to expanding the application vision of matplotlib, and the sample code in the case only involves the basic knowledge of Python. In this way, in the practice of Python data visualization, it is beneficial for readers to focus their time and energy on systematically mastering matplotlib knowledge and skills, and comprehensively improve their understanding and application level of matplotlib. Part 1 Graphics Chapter 1 Filling geometric shapes with color.................................................................. 2 1.1 Filling polygons with color.................................................................................................. 2 1.1.1 Filling regular polygons with color.................................................................................. 2 1.1.2 Filling irregular polygons with color.................................................................................. 4 1.2 Filling intersecting curves with color.................................................................................. 5 1.3 Further reading................................................................................................................ 6 1.3.1 How to fill horizontal intersecting curves with color................................................. 6 1.3.2 How to fill vertical intersecting curves with color................................................. 8 1.4 Comprehensive case: Filling intersecting discontinuous curves with color.................................. 9 Chapter 2 Using the patches module to draw geometric shapes.................................................. 12 2.1 How to implement a circle........................................................................................................ 12 2.2 How to implement an ellipse.................................................................................................. 15 2.3 How to implement rectangles................................................................................................... 17 2.4 How to draw arcs and wedges.................................................................................................. 19 2.5 Further reading.......................................................................................................................... 22 2.5.1 How to draw a circle using a line................................................................................. 22 2.5.2 How to draw a circle using an ellipse................................................................................ 25 2.5.3 How to draw a pie chart using a wedge................................................................................ 26 2.5.4 How to draw a donut-shaped pie chart using a wedge................................................. 28 Chapter 3 Combining statistical graphics................................................................................. 31 3.1 Discriminant analysis diagram in machine learning................................................. 31 3.2 Date-type time series graph................................................................................................. 33 3.3 Adding a probability density curve to a histogram................................................................. 35 3.4 Nesting a sub-plotting area in a plotting area.............................................................. 39 3.5 Further reading: Setting general date tick marks............................................................ 42 Part 2 Elements Chapter 4 Setting the style and layout of text content.................................. 45 4.1 Display style of text annotations.................................................................................. 45 4.1.1 Text box style.................................................................................................. 46 4.1.2 Text annotation arrow style................................................................................ 47 4.2 Layout of text content.................................................................................................. 49 4.3 Further reading.......................................................................................................................... 54 4.3.1 Automatic text wrapping.................................................................................. 54 4.3.2 Rotation angle of text content.................................................................. 57 4.3.3 Rotation mode of text content.................................................................................. 59 4.3.4 Alignment of multi-line text.................................................................................. 63 4.3.5 Connection Style of Text Annotation Arrows.................................................................. 66 Chapter 5 Adjusting Measurement Units and Measurement Methods................................................. 76 5.1 Implementation Methods of Different Measurement Units................................................................. 76 5.1.1 Implementation Methods of Radians and Angles................................................................. 76 5.1.2 Implementation Methods of Centimeters and Inches................................................................ 78 5.1.3 Implementation Methods of Seconds, Hertz, and Minutes................................................................ 80 5.1.4 Setting Methods of Coordinate System for Text Annotation Positions....................... 81 5.2 Operation Principles of Different Measurement Methods................................................................. 83 Chapter 6 Adjusting the Display Effect of Tick Marks, Tick Labels, and Axis Spine................... 87 6.1 Adjusting the Position of Tick Marks, Tick Labels, and Axis Labels....................................... 87 6.2 6.3 Adjustment of major and minor tick marks.................................................................. 92 6.4 Display and hide axis spines.................................................................................. 95 6.5 Adjustment of axis spine position.................................................................................. 98 Part 3 Interaction Chapter 7 Implementing graphic animation effects.......................................................................... 104 7.1 Use the animation module to draw animations.................................................................. 104 7.2 Call the pyplot module API to draw animations.................................................. 106 Chapter 8 Implementing GUI effects.................................................................................. 110 8.1 How to use the RadioButtons class...................................................................................110 8.2 How to use the Cursor class...................................................................................................113 8.3 How to use the CheckButtons class...................................................................................114 Chapter 9 Implementing event processing effects.................................................................. 118 9.1 The event result prompt appears after clicking to close the canvas....................................... 118 9.2 How to implement the partial zoom effect of the canvas.................................................. 120 Part 4 Exploration Chapter 10 Importing images from the outside to the drawing area........................................ 124 10.1 10.2 Relief Maps........................................................................................................................ 126 10.3 Heat Maps........................................................................................................................ 127 10.4 Setting Hyperlinks for Images................................................................................. 131 10.5 Adding External Images to the Canvas Layer................................................................... 136 10.6 Using Filters to Create Diverse Display Effects for Images....................... 140 10.6.1 Flipping Colors................................................................................................. 145 10.6.2 Converting RGB Channel NumPy Arrays to Single Channel NumPy Arrays........ 146 Chapter 11 Drawing 3D Graphics.................................................................................. 150 11.1 Drawing a Color Surface with a Color Scale.................................................................. 150 11.2 Drawing a Color Surface in 3D 11.3 Draw a scatter plot in 3D space.......................................................................................... 154 Chapter 12 Mapping.................................................................................................................. 156 12.1 Population of Australia’s capital and capital cities.................................................. 156 12.2 Current day and night geographic distribution map................................................. 160 12.3 Visualization of the distance between cities.................................................................162 Chapter 13 Comprehensive cross-application scenarios.................................................................. 167 13.1 Input data can use strings instead of variables.................................................. 167 13.2 Store canvas graphics in PDF file format................................................................. 169 13.3 Call pyplot API and object-oriented API to set graphics properties........ 171 13.4 Use a tree diagram to display the file size in the folder................................. 172 13.5 How to set the matplotlib style set................................................................. 176 13.6 How to configure the matplotlib backend type.................................................. 181 Part 5 Extension Chapter 14 Use LaTeX and matplotlib\'s own TeX function to render text content.... 187 14.1 Preparation steps.................................................................................................. 187 14.2 Case presentation.................................................................................................. 188 14.3 Further reading................................................................................................... 190 Chapter 15 Methods and techniques for writing mathematical expressions using matplotlib........ 193 15.1 Rules for editing strings.................................................................................. 193 15.2 Setting the font effect of output strings....................................................... 194 15.3 Learning the writing rules of TeX symbols through mathematical formulas and mathematical expressions.. 195 15.4 Learning the writing rules of TeX symbols through mathematical symbols and Greek letters........ 204 Appendix A How to install SciPy.................................................................................. 209 Appendix B How to use IPython........................................................................................ 211 Appendix C How to install and use the mpl_toolkits package.................................. 221 Appendix D Recommendations for using the software versions of Python 2 and Python 3.................. 226........................................................................................................................ 187 14.2 Case Presentation................................................................................................... 188 14.3 Further Reading...................................................................................................... 190 Chapter 15 Methods and Techniques for Writing Mathematical Expressions with Matplotlib........ 193 15.1 Rules for Editing Strings................................................................................................... 193 15.2 Setting the Font Effect of Output Strings................................................................... 194 15.3 Learning the Writing Rules of TeX Symbols through Mathematical Formulas and Expressions........ 195 15.4 Learning the Writing Rules of TeX Symbols through Mathematical Symbols and Greek Letters........ 204 Appendix A How to Install SciPy................................................................................... 209 Appendix B How to Use IPython................................................................................................... 211 Appendix C How to Install and Use the mpl_toolkits Package.................................................. 221 Appendix D Recommendations for using Python 2 and Python 3 software versions................................... 226........................................................................................................................ 187 14.2 Case Presentation................................................................................................... 188 14.3 Further Reading...................................................................................................... 190 Chapter 15 Methods and Techniques for Writing Mathematical Expressions with Matplotlib........ 193 15.1 Rules for Editing Strings................................................................................................... 193 15.2 Setting the Font Effect of Output Strings................................................................... 194 15.3 Learning the Writing Rules of TeX Symbols through Mathematical Formulas and Expressions........ 195 15.4 Learning the Writing Rules of TeX Symbols through Mathematical Symbols and Greek Letters........ 204 Appendix A How to Install SciPy................................................................................... 209 Appendix B How to Use IPython................................................................................................... 211 Appendix C How to Install and Use the mpl_toolkits Package.................................................. 221 Appendix D Recommendations for using Python 2 and Python 3 software versions................................... 226
pdf
Python Data Analysis: Dynamic Visualization Drawing Based on Plotly (Sun Yangyang)
Points it Requires : 1 Type:Technical DocumentationUploader:抛砖引玉Date:2023-05-28
Introduction:With the development of information technology and the reduction of hardware equipment costs, there is a huge amount of data on the Internet today. In order to quickly obtain more effective information from this data, data visualization is an important part. For Python language, the more traditional data visualization module is Matplotlib, but it has shortcomings such as not being beautiful enough, static, and not easy to share, which limits the development of Python in data visualization. In order to solve this problem, a new dynamic visualization open source module Plotly came into being. Because Plotly has the characteristics of being dynamic, beautiful, easy to use, and rich in variety, it has been loved by developers as soon as it came out. This book mainly introduces the application of Plotly in various fields of visualization, including basic drawing, data processing, web development, program GUI, machine learning, and quantitative investment, so that readers can quickly get started with Plotly. Most of the code in this book is written in Python, and application cases of Plotly in R, MATLAB, and JavaScript are also given. 1.1 Introduction to Plotly1.2 Installation and Installation Environment1.3 Online Initialization1.4 Online Drawing Privacy Statement1.5 Start Online Drawing1.6 Use Offline Drawing Library1.7 Parameter Interpretation1.8 View HelpChapter 2 Basic Plotly Graphics2.1 Interpretation of Basic Cases2.2 Basic Drawing Process2.3 Scatter Plot2.3.1 Basic Case2.3.2 Style Setting2.3.3 Application Case2.3.4 Parameter Interpretation2.4 Bubble Plot2.4.1 Basic Case2.4.2 Style Setting2.4.3 Zoom Setting2.4.4 Parameter Interpretation2.5 Line Plot2.5.1 Basic Case2.5.2 Data Gaps and Connections2.5.3 Data Interpolation2.5.4 Filled Line Plot2.5.5 Application Case2.5.6 Parameter Interpretation2.6 Bar Plot2.6.1 Basic Bar Plot2.6.2 Bar Cluster2.6.3 Stacked column chart2.6.4 Waterfall column chart2.6.5 Graphic style setting2.6.6 Application case2.6.7 Parameter interpretation2.7 Horizontal bar chart2.7.1 Basic case2.7.2 Application case2.7.3 Parameter interpretation2.8 Gantt chart2.8.1 Basic Gantt chart2.8.2 Gantt chart (indexed by numbers)2.8.3 Gantt chart (indexed by categories)2.8.4 Application case2.9 Area chart2.9.1 Basic area chart2.9.2 Filled area chart2.9.3 Stacked area chart2.10 Histogram2.10.1 Basic histogram2.10.2 Overlapped histogram2.10.3 Stacked histogram2.10.4 Cumulative histogram2.10.5 Application case2.10.6 Parameter interpretation2.11 Pie chart2.11.1 Basic pie chart2.11.2 Ring pie chart2.11.3 Style setting2.11.4 Application examples2.11.5 Parameter interpretation2.12 More examples2.13 Overview of Plotly objectsChapter 3 Plotly advanced graphics3.1 Time series3.1.1 Usage3.1.2 Time range constraints3.2 Slide selection control3.3 Table3.3.1 Getting started case3.3.2 Adding links3.3.3 Using Pandas3.3.4 Changing size and color3.3.5 Table and figure3.4 Multiple charts3.5 Multiple coordinate axes3.5.1 Dual coordinate axes3.5.2 Multiple coordinate axes3.5.3 Shared coordinate axes3.6 Multiple sub-charts3.6.1 Dual sub-charts (method one) 3.6.2 Dual sub-charts (method two) 3.6.3 Multiple sub-charts (method one) 3.6.4 Multiple subgraphs (method 2) 3.6.5 Split view intervals 3.6.6 Subgraphs share coordinate axes (method 1) 3.6.7 Subgraphs share coordinate axes (method 2) 3.6.8 Customize subgraph coordinate axes 3.6.9 Embedded subgraphs 3.6.10 Mixed graphs 3.7 Drawing SVG 3.7.1 Drawing line graphs 3.7.2 Application of line graphs: Creating tangent lines of graphs 3.7.3 Drawing rectangular graphs 3.7.4 Application of rectangular graphs: Setting time series area highlights 3.7.5 Drawing circular graphs 3.7.6 Application of circular graphs: Highlighting clusters of scatter plots Chapter 4 Plotly and Pandas 4.1 Simple and quick start 4.1.1 Basic line graphs 4.1.2 Basic scatter plots 4.1.3 Basic bar graphs 4.2 Drawing with cufflinks 4.2.1 Install cufflinks 4.2.2 Quick Start4.2.3 Quick Data Acquisition4.2.4 Custom Drawing4.2.5 Common Classic Graphics4.2.6 More ExamplesChapter 5 Financial Drawing5.1 Quick Drawing of K-line Charts5.1.1 Check Plotly Version5.1.2 Quick Drawing of OHLC (US Line) Charts5.1.3 Quick Drawing of Candlestick Charts5.2 Optimization of K-line Charts5.2.1 Filtering Non-trading Time5.2.2 Setting Shape, Color and Annotation5.2.3 Adding Technical Indicators5.3 Financial Drawing Using Custom Data5.4 Advanced Financial Drawing5.4.1 Getting Started Case5.4.2 Comprehensive CaseChapter 6 Matplotlib 6.1 Introduction to Matplotlib6.2 Installing Matplotlib 6.3 Adjusting Matplotlib Parameters6.4 Common API Functions6.5 Linear Functions6.6 Adding Subgraphs6.7 Determining Coordinate Range6.8 Probability Charts6.9 Scatter Charts6.10 6.1.1 Introduction to Python 7.1.2 Introduction to Python 7.1.3 Introduction to Python 7.1.4 Introduction to Python 7.1.5 Introduction to Python 7.1.6 Introduction to Python 7.1.7 Introduction to Python 7.2.1 Introduction to Python 7.2.2 Introduction to Python 7.2.3 Introduction to Python 7.2.4 Introduction to Python 7.2.5 Introduction to Python 7.2.6 Introduction to Python 7.2.7 Introduction to Python 7.2.8 Introduction to Python 7.2.9 Introduction to Python 8.3 Introduction to Python 8.4 Introduction to Python 8.5 Introduction to Python 8.6 Introduction to Python 8.7 Introduction to Python 8.8 8.8 Application Case: Displaying Product Portfolio InformationChapter 9 Plotly and Machine Learning9.1 Application of Plotly in Sklearn9.1.1 Classification Problem9.1.2 Regression Problem9.1.3 Clustering Problem9.2 PyTorch Visualization Tool9.2.1 Introduction to Visdom9.2.2 Install Visdom9.2.3 Visdom and Plotly9.2.4 Basic Concepts of Visdom9.2.5 Classic Cases of Visdom9.2.6 Visdom and PyTorchChapter 10 Application of Plotly in Quantitative InvestmentChapter 11 Application of Plotly in Other Languages11.1 Application of Plotly in R Language11.1.1 Install R Language11.1.2 Install Plotly Module11.1.3 Plotly Application Analysis11.1.4 More Extensions11.2 Application of Plotly in MATLAB11.2.1 Download and Installation11.2.2 Basic Introduction11.2.3 Classic Cases11.2.4 More Extensions11.3 Application of Plotly in JavaScript11.3.1 Basics11.3.2 Scatter Plot11.3.3 Bar Chart11.3.4 Pie Chart11.3.5 More Extensions
pdf
Python - Pandas Tutorial
Points it Requires : 5 Type:Technical DocumentationUploader:哈哈88Date:2019-07-14
Introduction:Use pandas for data analysis. Pandas can realize your unexpected data processing world. With it, you can easily operate all data...
pdf
Machine Learning Numpy and Pandas Basics
Points it Requires : 1 Type:Application DocumentsUploader:太白金星Date:2021-05-30
Introduction:Machine Learning Numpy and Pandas Basics

Latest Downloading

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
×

已收藏到:个人中心—我的下载—收藏