# Python Basics

 


<style>
 @import url("./custom/gtag.js");
</style>

Please refer to [python 3 documentation](https://docs.python.org/3/)

<h4 style='color:black;text-align:center;'><space>Table of Contents</h4> 


|  | 
| :--- |
| [Numpy and Linear Algebra](#Numpy-and-Linear-Algebra)   | 
| [Matrices with sympy](#Matrices-with-sympy)   |   
| [Scipy and Matplotlib Plotting](#Scipy-and-Matplotlib-Plotting)  |   
| [Control/Conditional Statements](#Control/Conditional-Statements)   |   
| [Creating Methods](#Creating-Methods)   |  
| [Strings](#Strings)  |
| [Pandas - DataFrame](#Pandas-intro-using-DataFrame) |



## Numpy and Linear Algebra


```python
import numpy as np
# Creating two lists, a and b
a=[1,2,3] 
b=[4,5,6]
c=np.concatenate((a,b))
print(c)
```

    [1 2 3 4 5 6]



```python
## Logial operations are element-wise ##
# Create an array
f = np.array([1,2,3,4,5])
print('This is the frist output: ',f < 4)
print('This is the second output: ',(f<4) | (f>4)) # | is logical symbol for 'or'
```

    This is the frist output:  [ True  True  True False False]
    This is the second output:  [ True  True  True False  True]



```python
## Sums and Averages of elements inside array##
g = np.array([[1,2,3],[4,5,6]])
print(g)
g.sum()
```

    [[1 2 3]
     [4 5 6]]





    21




```python
g.sum(axis=1)
```




    array([ 6, 15])




```python
g.mean()
```




    3.5




```python
g.std()
```




    1.707825127659933




```python
# If we are not sure what a function or object is, then
# we can look to the help page.
help(g.std)
```

    Help on built-in function std:
    
    std(...) method of numpy.ndarray instance
        a.std(axis=None, dtype=None, out=None, ddof=0, keepdims=False)
        
        Returns the standard deviation of the array elements along given axis.
        
        Refer to `numpy.std` for full documentation.
        
        See Also
        --------
        numpy.std : equivalent function
    



```python
g.std(axis=1)
```




    array([0.81649658, 0.81649658])




```python
# Take two matrices, a and b, then concatenate them.
a=np.array([[1,2,3],[4,5,6]])
b=np.array([[1,2,3],[7,8,9]])
c=np.concatenate((a,b))
print(c)
```

    [[1 2 3]
     [4 5 6]
     [1 2 3]
     [7 8 9]]



```python
d = np.transpose(c) # transpose of c
f = d[:,0:3] # first 3 columns of d
g = np.eye(3) # identity 3x3
h = np.concatenate((f,g), axis=0) # linking f and g
I = np.concatenate((f,g), axis=1) # linking f and g
print(I) # axis=1
```

    [[1. 4. 1. 1. 0. 0.]
     [2. 5. 2. 0. 1. 0.]
     [3. 6. 3. 0. 0. 1.]]


## Matrices with sympy


```python
# Lets use sympy to construct a matrix
## Matrices from docs.sympy.org ##
from sympy import *
# We can also make the output look pretty
init_printing(use_unicode=True)
M = Matrix([[1,2,3],[4,5,6],[7,8,9]])
print('Row Reduce Echelon Form of the Matrix M is:\n')
M.rref()
```

    Row Reduce Echelon Form of the Matrix M is:
    





$$\left ( \left[\begin{matrix}1 & 0 & -1\\0 & 1 & 2\\0 & 0 & 0\end{matrix}\right], \quad \left ( 0, \quad 1\right )\right )$$




```python
print("See, we can still print, but it doesn't look as nice\n",M)
```

    See, we can still print, but it doesn't look as nice
     Matrix([[1, 2, 3], [4, 5, 6], [7, 8, 9]])



```python
A = Matrix([[1,2,3],[4,5,6],[7,8,9]])
```


```python
# If you need an immutable version of Matrix, use ImmutableMatrix
A.shape
```


```python
# to get individual rows of columns, use:
A.row(0)
A.col(1)
```




$$\left[\begin{matrix}2\\5\\8\end{matrix}\right]$$




```python
# deleting and inserting rows and columns
A.row_del(1)
A
```




$$\left[\begin{matrix}1 & 2 & 3\\7 & 8 & 9\end{matrix}\right]$$




```python
A.T
```




$$\left[\begin{matrix}1 & 7\\2 & 8\\3 & 9\end{matrix}\right]$$




```python
A = Matrix([[2,3,4],[5,8,3],[3,3,3]])
A
```




$$\left[\begin{matrix}2 & 3 & 4\\5 & 8 & 3\\3 & 3 & 3\end{matrix}\right]$$




```python
A.rref() # (rref, pivot columns)
```




$$\left ( \left[\begin{matrix}1 & 0 & 0\\0 & 1 & 0\\0 & 0 & 1\end{matrix}\right], \quad \left ( 0, \quad 1, \quad 2\right )\right )$$




```python
A.nullspace()
```


```python
B = Matrix([[1,2,3],[4,5,6],[7,8,9]])
B
```




$$\left[\begin{matrix}1 & 2 & 3\\4 & 5 & 6\\7 & 8 & 9\end{matrix}\right]$$




```python
B.rref()
```




$$\left ( \left[\begin{matrix}1 & 0 & -1\\0 & 1 & 2\\0 & 0 & 0\end{matrix}\right], \quad \left ( 0, \quad 1\right )\right )$$




```python
B.nullspace()
```




$$\left [ \left[\begin{matrix}1\\-2\\1\end{matrix}\right]\right ]$$




```python
## Eigenvalues and Eigenvectors ##
A.eigenvals() # returns (eigenvalue:algebraic multiplicity)
```


```python
A.eigenvects()
# which returns (eigenvalue:algebraic multiplicity, [eigenvectors])
```




$$\left [ \left ( -1, \quad 1, \quad \left [ \left[\begin{matrix}- \frac{9}{4}\\\frac{11}{12}\\1\end{matrix}\right]\right ]\right ), \quad \left ( 2, \quad 1, \quad \left [ \left[\begin{matrix}1\\- \frac{4}{3}\\1\end{matrix}\right]\right ]\right ), \quad \left ( 12, \quad 1, \quad \left [ \left[\begin{matrix}1\\2\\1\end{matrix}\right]\right ]\right )\right ]$$




```python
## dagonlizable matrices ##
#  A = PDP^-1
P, D = A.diagonalize()
print(P)
print(D)
```

    Matrix([[-27, 3, 1], [11, -4, 2], [12, 3, 1]])
    Matrix([[-1, 0, 0], [0, 2, 0], [0, 0, 12]])



```python
# remember that lambda is a reserved keyword in python, so
# to create the symbol use: lamda (without the 'b')

lamda = symbols('lamda')

B = Matrix([[1, 0 , 1],[1, 1, 2], [ 1, 0, 1]])
B

b = B.charpoly(lamda)
b

factor(b)
```

## Scipy and Matplotlib Plotting


```python
x = symbols('x')
y = x**2 + 5*x + 6
print(y)
```

    x**2 + 5*x + 6



```python
y_x = integrate(y)
pprint(y_x)
```

     3      2      
    x    5⋅x       
    ── + ──── + 6⋅x
    3     2        



```python
## Constructing a large lil_matrix and add values to it ##
from scipy.sparse import lil_matrix
from scipy.sparse.linalg import spsolve
from numpy.linalg import solve, norm
from numpy.random import rand
## Optimization ##
#Minimization (steepest-decentm conjugate gradient), curve-fitting, least squares, root finding (Newton's method), annealing, etc. 
import scipy.optimize as optimize
```


```python
## Curve Fitting Example ##
def func(x,a,b,c):
    return a*np.exp(-b*x) + c
```


```python
x = np.linspace(0,4,50) # 50 values linearly in [0,4]
y = func(x,2.5,1.3,0.5)
yn = y + 0.2*np.random.normal(size=len(x))
popt,pcov = optimize.curve_fit(func,x,yn)
popt,pcov # optimized parameters and their covariance
```




    (array([2.68646283, 1.51320963, 0.53692262]),
     array([[ 0.01767912,  0.00851316, -0.00063102],
            [ 0.00851316,  0.02293804,  0.00501921],
            [-0.00063102,  0.00501921,  0.00242487]]))




```python
## Matplotlib ##
from matplotlib.pyplot import *
from pylab import *
x = np.arange(0,10,0.2)
y = np.cos(x)
figure()
```




    <Figure size 640x480 with 0 Axes>




```python
plot(x,y,'g*')
show()
```


```python
# or we can show the figure inline
%matplotlib inline
plot(x,-np.exp(2*y),'g*')
```

## Control/Conditional Statements


```python
## Contidtionsl and Flow Statements ##

## 'if' Statement
x = int(1) # Change the initial condition to alt output
if x < 0:
    x = 0
    print('Negative goes to zero')
elif x == 0:
    print('Zero')
elif x == 1:
    print('single')
else:
    print('More')
```

    single



```python
##  Examples using 'for' statement
# create a list of names
Names = ['Rob', 'Ron', 'Felish', 'George', 'Shoe']
for x in Names:
    # print the ith element of the list, followed by 
    # the number of charecters the name has. 
    print(x, len(x))

# Here's another way to do the same thing...
# but let x be the ith iteration.
Names = ['Rob', 'Ron', 'Felish', 'George', 'Shoe']
for i in range(len(Names)):
    print(i,Names[i])
```

    Rob 3
    Ron 3
    Felish 6
    George 6
    Shoe 4
    0 Rob
    1 Ron
    2 Felish
    3 George
    4 Shoe



```python
for x in range(5):    # range(5) = {0,1,2,3,4}
    if x == 3:        # if x=3, print out the string
        print('Three')
    elif x == 0:      # "elseif" needed after 'if' to continue with condiditions of the same statement
        print('Zero')
    else:             # otherwise, print out the remaining
        print(x)
```

    Zero
    1
    2
    Three
    4



```python
for x in Names[:]: # Loops over a slice copy of the entire list.
    if len(x) > 5:
        Names.remove(x)
        Names.append('Name')
        
Names
```




    ['Rob', 'Ron', 'Shoe', 'Name', 'Name']




```python
## 'break' and 'continue' Statements, and 'else' Clauses on loops
## Prime Numbers ##
for n in range(2,50):
    for x in range(2, n):
        if n % x == 0:
            print(n, '=', x, '*', n/x)
            break
    else:
        # loop fell through without finding a factor
        print(n, 'is a prime number')
        
```

    2 is a prime number
    3 is a prime number
    4 = 2 * 2.0
    5 is a prime number
    6 = 2 * 3.0
    7 is a prime number
    8 = 2 * 4.0
    9 = 3 * 3.0
    10 = 2 * 5.0
    11 is a prime number
    12 = 2 * 6.0
    13 is a prime number
    14 = 2 * 7.0
    15 = 3 * 5.0
    16 = 2 * 8.0
    17 is a prime number
    18 = 2 * 9.0
    19 is a prime number
    20 = 2 * 10.0
    21 = 3 * 7.0
    22 = 2 * 11.0
    23 is a prime number
    24 = 2 * 12.0
    25 = 5 * 5.0
    26 = 2 * 13.0
    27 = 3 * 9.0
    28 = 2 * 14.0
    29 is a prime number
    30 = 2 * 15.0
    31 is a prime number
    32 = 2 * 16.0
    33 = 3 * 11.0
    34 = 2 * 17.0
    35 = 5 * 7.0
    36 = 2 * 18.0
    37 is a prime number
    38 = 2 * 19.0
    39 = 3 * 13.0
    40 = 2 * 20.0
    41 is a prime number
    42 = 2 * 21.0
    43 is a prime number
    44 = 2 * 22.0
    45 = 3 * 15.0
    46 = 2 * 23.0
    47 is a prime number
    48 = 2 * 24.0
    49 = 7 * 7.0



```python
## Even and Odd example
for n in range(2, 10):
    if n % 2 == 0:
        print('Found an even number', n)
        continue
    print('Found an odd number', n)

## 'pass' Statements

# pass statement does nothin.  It can be used requires no action.
# It can be used for creaing minimal classes.
# It can also be used as a place-holder for a function
def initlog(*arguments):
    pass  # remember to implement this!
```

    Found an even number 2
    Found an odd number 3
    Found an even number 4
    Found an odd number 5
    Found an even number 6
    Found an odd number 7
    Found an even number 8
    Found an odd number 9


## Creating Methods


```python
## Defining Functions ##
def fib(n):  # write Fibonacci series up to n
    """Print a Fibonacci series up to n."""
    a,b = 0,1
    while a < n:
        print(a,)
        a,b = b,a+b
        
# Now, calling on the function just made
fib(2000)
```

    0
    1
    1
    2
    3
    5
    8
    13
    21
    34
    55
    89
    144
    233
    377
    610
    987
    1597



```python
## changing fib to fib2
def fib2(n):  # write Fibonacci series up to n
    """Return a list containing the Fibonacci series up to n."""
    result = []
    a,b = 0,1
    while a < n:
        result.append(a) 
        a,b = b,a+b
    return result
        
fib2(100)
```


```python
 #The return statement returns with a value from a function.
 #return without an expression arugment returns None.
 #The statement result.append(a) calls a method of the list object result.
 #A method i a function that belongs to an object and is named obj.methodname

def f(a, L=[]):
    L.append(a)
    return L

print(f(1))
print(f(2))
print(f(3))
print(f(100))
```

    [1]
    [1, 2]
    [1, 2, 3]
    [1, 2, 3, 100]



```python
# If you dont want the default to be shared with subsequent calls...
def f(a, L=None):
    if L is None:
        L = [] # generate a new list every iteration
    L.append(a)
    return L

print(f(0))
print(f(1))
print(f(2))
print(f(100))
```

    [0]
    [1]
    [2]
    [100]



```python
## Keyword Arguments ##
# which are of the form: kwarg=value
# In general:
# def func(required, state, action, type):

# lets make one up...
food=['apple', 'organges', 'bread', 'salad']
def store(food, state='need', action='buy', type='cash'):
    if food == 'salad':
        print('This store has the groceries I', state,',' )
        print("but doesn't have", food, )
    elif food == 'organges':
        print('They have', food, 'but I have insignificant', type,)
    
```


```python
store('salad')
# This needs work (not finished)
```

    This store has the groceries I need ,
    but doesn't have salad



```python
## The template for writing a function ##

def my_function():
    '''Insert a short, concise summary of the object's purpose.'''
    pass

print(help(my_function)) # just showing the docstring for the function
```

    Help on function my_function in module __main__:
    
    my_function()
        Insert a short, concise summary of the object's purpose.
    
    None


## Strings


```python
name = 'Enter Name Here'  # Enter your name here
intro = 'Hello, my name is %s.'%(name)

## Let's do some string minipulation...

# First, lets separate this statement by each space 
# we can put each word into a list 
List = [word for word in intro.split(" ")]
print(List)
```

    ['Hello,', 'my', 'name', 'is', 'Enter', 'Name', 'Here.']



```python
# We can get rid of any punctuation marks with replace
List = [word.replace(".","").replace(",","") for word in intro.split(" ")]
print(List)
```

    ['Hello', 'my', 'name', 'is', 'Enter', 'Name', 'Here']



```python
# We can print the length of the list (number of words)
print(len(List))
```

    7



```python
# We can print the length of each element in the list (number of characters)
nChar = 0  # start a count of the number of characters 
for i in range(len(List)):
    nChar += len(List[i])
    print('Word %i/%i has %i characters.'%(i+1,len(List),len(List[i])))
print('The total number of characters in the list is %i'%nChar)
```

    Word 1/7 has 5 characters.
    Word 2/7 has 2 characters.
    Word 3/7 has 4 characters.
    Word 4/7 has 2 characters.
    Word 5/7 has 5 characters.
    Word 6/7 has 4 characters.
    Word 7/7 has 4 characters.
    The total number of characters in the list is 26


## Pandas intro using `DataFrame`


```python
import pandas as pd
```


```python
m = 5  # number of participants or "members"
n = 10 # number of observations of position

observation_times = pd.Series(["01-%0.2i-2020"%i for i in range(n)])
# You can do the same thing using:  dates_index = pd.date_range("20200101", periods=m)
array = np.random.random((n,m)) # creating a bunch (n x m) of random samples
samples = pd.DataFrame(array, index=observation_times, columns=["m%i"%i for i in range(m)])
samples
```




<div>
<style scoped>
    .dataframe tbody tr th:only-of-type {
        vertical-align: middle;
    }

    .dataframe tbody tr th {
        vertical-align: top;
    }

    .dataframe thead th {
        text-align: right;
    }
</style>
<table border="1" class="dataframe">
  <thead>
    <tr style="text-align: right;">
      <th></th>
      <th>m0</th>
      <th>m1</th>
      <th>m2</th>
      <th>m3</th>
      <th>m4</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <th>01-00-2020</th>
      <td>0.037611</td>
      <td>0.656845</td>
      <td>0.140001</td>
      <td>0.886104</td>
      <td>0.667229</td>
    </tr>
    <tr>
      <th>01-01-2020</th>
      <td>0.647753</td>
      <td>0.977726</td>
      <td>0.295408</td>
      <td>0.732274</td>
      <td>0.310976</td>
    </tr>
    <tr>
      <th>01-02-2020</th>
      <td>0.025785</td>
      <td>0.764663</td>
      <td>0.889219</td>
      <td>0.635461</td>
      <td>0.248914</td>
    </tr>
    <tr>
      <th>01-03-2020</th>
      <td>0.077782</td>
      <td>0.977541</td>
      <td>0.126935</td>
      <td>0.937189</td>
      <td>0.735266</td>
    </tr>
    <tr>
      <th>01-04-2020</th>
      <td>0.751781</td>
      <td>0.658810</td>
      <td>0.222319</td>
      <td>0.410867</td>
      <td>0.703010</td>
    </tr>
    <tr>
      <th>01-05-2020</th>
      <td>0.671324</td>
      <td>0.114019</td>
      <td>0.147262</td>
      <td>0.568094</td>
      <td>0.009472</td>
    </tr>
    <tr>
      <th>01-06-2020</th>
      <td>0.931435</td>
      <td>0.436208</td>
      <td>0.370047</td>
      <td>0.752514</td>
      <td>0.038555</td>
    </tr>
    <tr>
      <th>01-07-2020</th>
      <td>0.464833</td>
      <td>0.739809</td>
      <td>0.938925</td>
      <td>0.300964</td>
      <td>0.080938</td>
    </tr>
    <tr>
      <th>01-08-2020</th>
      <td>0.512085</td>
      <td>0.142006</td>
      <td>0.008359</td>
      <td>0.195520</td>
      <td>0.947673</td>
    </tr>
    <tr>
      <th>01-09-2020</th>
      <td>0.490614</td>
      <td>0.539010</td>
      <td>0.972949</td>
      <td>0.687977</td>
      <td>0.869855</td>
    </tr>
  </tbody>
</table>
</div>




```python
# gather specific memembers
sub_samples = samples[["m2","m4"]] # grabbing only the 2nd and 4th members
sub_samples
```




<div>
<style scoped>
    .dataframe tbody tr th:only-of-type {
        vertical-align: middle;
    }

    .dataframe tbody tr th {
        vertical-align: top;
    }

    .dataframe thead th {
        text-align: right;
    }
</style>
<table border="1" class="dataframe">
  <thead>
    <tr style="text-align: right;">
      <th></th>
      <th>m2</th>
      <th>m4</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <th>01-00-2020</th>
      <td>0.140001</td>
      <td>0.667229</td>
    </tr>
    <tr>
      <th>01-01-2020</th>
      <td>0.295408</td>
      <td>0.310976</td>
    </tr>
    <tr>
      <th>01-02-2020</th>
      <td>0.889219</td>
      <td>0.248914</td>
    </tr>
    <tr>
      <th>01-03-2020</th>
      <td>0.126935</td>
      <td>0.735266</td>
    </tr>
    <tr>
      <th>01-04-2020</th>
      <td>0.222319</td>
      <td>0.703010</td>
    </tr>
    <tr>
      <th>01-05-2020</th>
      <td>0.147262</td>
      <td>0.009472</td>
    </tr>
    <tr>
      <th>01-06-2020</th>
      <td>0.370047</td>
      <td>0.038555</td>
    </tr>
    <tr>
      <th>01-07-2020</th>
      <td>0.938925</td>
      <td>0.080938</td>
    </tr>
    <tr>
      <th>01-08-2020</th>
      <td>0.008359</td>
      <td>0.947673</td>
    </tr>
    <tr>
      <th>01-09-2020</th>
      <td>0.972949</td>
      <td>0.869855</td>
    </tr>
  </tbody>
</table>
</div>




```python
sub_samples.sum()
```




    m2    4.111425
    m4    4.611888
    dtype: float64




```python
# Subtract the element one row up from the current row
sub_samples.diff(periods=1, axis=0)
```




<div>
<style scoped>
    .dataframe tbody tr th:only-of-type {
        vertical-align: middle;
    }

    .dataframe tbody tr th {
        vertical-align: top;
    }

    .dataframe thead th {
        text-align: right;
    }
</style>
<table border="1" class="dataframe">
  <thead>
    <tr style="text-align: right;">
      <th></th>
      <th>m2</th>
      <th>m4</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <th>01-00-2020</th>
      <td>NaN</td>
      <td>NaN</td>
    </tr>
    <tr>
      <th>01-01-2020</th>
      <td>0.155408</td>
      <td>-0.356254</td>
    </tr>
    <tr>
      <th>01-02-2020</th>
      <td>0.593811</td>
      <td>-0.062061</td>
    </tr>
    <tr>
      <th>01-03-2020</th>
      <td>-0.762284</td>
      <td>0.486351</td>
    </tr>
    <tr>
      <th>01-04-2020</th>
      <td>0.095384</td>
      <td>-0.032256</td>
    </tr>
    <tr>
      <th>01-05-2020</th>
      <td>-0.075058</td>
      <td>-0.693538</td>
    </tr>
    <tr>
      <th>01-06-2020</th>
      <td>0.222786</td>
      <td>0.029083</td>
    </tr>
    <tr>
      <th>01-07-2020</th>
      <td>0.568878</td>
      <td>0.042384</td>
    </tr>
    <tr>
      <th>01-08-2020</th>
      <td>-0.930566</td>
      <td>0.866734</td>
    </tr>
    <tr>
      <th>01-09-2020</th>
      <td>0.964590</td>
      <td>-0.077817</td>
    </tr>
  </tbody>
</table>
</div>




```python
# Subtract one column with the other
sub_samples.diff(periods=1, axis=1)
```




<div>
<style scoped>
    .dataframe tbody tr th:only-of-type {
        vertical-align: middle;
    }

    .dataframe tbody tr th {
        vertical-align: top;
    }

    .dataframe thead th {
        text-align: right;
    }
</style>
<table border="1" class="dataframe">
  <thead>
    <tr style="text-align: right;">
      <th></th>
      <th>m2</th>
      <th>m4</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <th>01-00-2020</th>
      <td>NaN</td>
      <td>0.527229</td>
    </tr>
    <tr>
      <th>01-01-2020</th>
      <td>NaN</td>
      <td>0.015567</td>
    </tr>
    <tr>
      <th>01-02-2020</th>
      <td>NaN</td>
      <td>-0.640305</td>
    </tr>
    <tr>
      <th>01-03-2020</th>
      <td>NaN</td>
      <td>0.608330</td>
    </tr>
    <tr>
      <th>01-04-2020</th>
      <td>NaN</td>
      <td>0.480691</td>
    </tr>
    <tr>
      <th>01-05-2020</th>
      <td>NaN</td>
      <td>-0.137790</td>
    </tr>
    <tr>
      <th>01-06-2020</th>
      <td>NaN</td>
      <td>-0.331493</td>
    </tr>
    <tr>
      <th>01-07-2020</th>
      <td>NaN</td>
      <td>-0.857987</td>
    </tr>
    <tr>
      <th>01-08-2020</th>
      <td>NaN</td>
      <td>0.939313</td>
    </tr>
    <tr>
      <th>01-09-2020</th>
      <td>NaN</td>
      <td>-0.103094</td>
    </tr>
  </tbody>
</table>
</div>




```python
# Another way of getting a subset...
samples[1:4]
```




<div>
<style scoped>
    .dataframe tbody tr th:only-of-type {
        vertical-align: middle;
    }

    .dataframe tbody tr th {
        vertical-align: top;
    }

    .dataframe thead th {
        text-align: right;
    }
</style>
<table border="1" class="dataframe">
  <thead>
    <tr style="text-align: right;">
      <th></th>
      <th>m0</th>
      <th>m1</th>
      <th>m2</th>
      <th>m3</th>
      <th>m4</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <th>01-01-2020</th>
      <td>0.647753</td>
      <td>0.977726</td>
      <td>0.295408</td>
      <td>0.732274</td>
      <td>0.310976</td>
    </tr>
    <tr>
      <th>01-02-2020</th>
      <td>0.025785</td>
      <td>0.764663</td>
      <td>0.889219</td>
      <td>0.635461</td>
      <td>0.248914</td>
    </tr>
    <tr>
      <th>01-03-2020</th>
      <td>0.077782</td>
      <td>0.977541</td>
      <td>0.126935</td>
      <td>0.937189</td>
      <td>0.735266</td>
    </tr>
  </tbody>
</table>
</div>




```python

```

351dc2788166f5c1ea6c6075d7e64c534a07d7ee
ipynb
Jupyter Notebook
Miscellaneous/Python_Lessons.ipynb
robraddi/tu_chem
18b8247d6c00e33f15f040a57a32b5fc2372137a
MIT
2021-04-29T04:26:42.000Z
2021-04-29T04:26:42.000Z
Miscellaneous/Python_Lessons.ipynb
robraddi/tu_chem
18b8247d6c00e33f15f040a57a32b5fc2372137a
MIT
Miscellaneous/Python_Lessons.ipynb
robraddi/tu_chem
18b8247d6c00e33f15f040a57a32b5fc2372137a
MIT
2020-12-03T17:47:05.000Z
2020-12-03T17:47:05.000Z
Qwen/Qwen-72B
1. YES
2. YES