<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 Title
Step1:  Define A Function, f(x)
Step2:  Create Some Values Of x
Step3:  Find The Argmin Of f(x)
Step4:  Check Our Results
<ASSISTANT_TASK:>
Python Code:
import numpy as np
import pandas as pd
np.random.seed(1)
Explanation: Title: argmin and argmax
Slug: argmin_and_argmax
Summary: An explanation of argmin and argmax in Python.  
Date: 2016-01-23 12:00
Category: Mathematics
Tags: Basics  
Authors: Chris Albon  
argmin and argmax are the inputs, x's, to a function, f, that creates the smallest and largest outputs, f(x).
Preliminaries
End of explanation
# Define a function that,
def f(x):
    # Outputs x multiplied by a random number drawn from a normal distribution
    return x * np.random.normal(size=1)[0]
Explanation: Define A Function, f(x)
End of explanation
# Create some values of x
xs = [1,2,3,4,5,6]
Explanation: Create Some Values Of x
End of explanation
#Define argmin that
def argmin(f, xs):
    # Applies f on all the x's
    data = [f(x) for x in xs]
    # Finds index of the smallest output of f(x)
    index_of_min = data.index(min(data))
        
    # Returns the x that produced that output
    return xs[index_of_min]
# Run the argmin function
argmin(f, xs)
Explanation: Find The Argmin Of f(x)
End of explanation
print('x','|', 'f(x)')
print('--------------')
for x in xs:
    print(x,'|', f(x))
Explanation: Check Our Results
End of explanation
<END_TASK>