Ipython Notebook
Command line Input Ipython notebook
At this point, the browser will automatically run and open the Ipython Web page
Basic operations
As shown, create a new project
Import related modules, set up a data set
Create a missing item and assign a value to the newly inserted part
This constructs a two-dimensional dataframe array that contains some empty data
There are generally two ways to process empty data
Dropna (), Fillna (values=5) with null values removed to replace null values with default values
Pd.isnull (DF1) can determine whether an element is empty data, plus any (). any () Boolean value that can be used for null data
Average calculation by column: (null value not participating in calculation)
Average calculation by row: (null value not participating in calculation)
Accumulate Values by column: (null value does not participate in calculation)
When subtracting an array of two dimensions, the subtracted array copies the dimensions of the current column complement the set of the meiosis, and the null value does not participate in the operation
Accumulate by line
Maximum value minus minimum for each column
The Apply function enters a sequence
Value_counts () View the number of occurrences of an element with. Mode () View the most frequently occurring elements
Create a random sequence first
Call Value_counts ()
Call. Mode () to see the most frequently occurring elements
Data merge
Create an array of 10*4 first
(1) Call the concat () function to merge the array (Concat accepts an array, which is the array to be merged)
See if the merged array is equal to the original array
Or
(2) Merge through merge, similar to table join Association
Create two arrays First
Call merge, which is equivalent to select * from the left inner join right on left.key = Right.key;
(3) Insert method Merge array
Create an array first
Call Append, if the number of inserted columns is different, the missing value
Classification statistics
Create an array first
A single pair of ' a ' groups, GroupBy (' a ')
Multi-Group, GroupBy ([])
Pandas Web page Operation Basics