notebook goes over how to load data from a pandas DataFrame.#!pip install pandasimport pandas as pddf = pd.read_csv("example_data/mlb_teams_2012.csv")df.head()<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>Team</th>      <th>"Payroll (millions)"</th>      <th>"Wins"</th>    </tr>  </thead>  <tbody>    <tr>      <th>0</th>      <td>Nationals</td>      <td>81.34</td>      <td>98</td>    </tr>    <tr>      <th>1</th>      <td>Reds</td>      <td>82.20</td>      <td>97</td>    </tr>    <tr>      <th>2</th>      <td>Yankees</td>      <td>197.96</td>      <td>95</td>    </tr>    <tr>      <th>3</th>      <td>Giants</td>      <td>117.62</td>      <td>94</td>    </tr>    <tr>      <th>4</th>      <td>Braves</td>      <td>83.31</td>      <td>94</td>    </tr>  </tbody></table></div>from langchain.document_loaders import DataFrameLoaderloader = DataFrameLoader(df, page_content_column="Team")loader.load()    [Document(page_content='Nationals', metadata={' "Payroll (millions)"': 81.34, ' "Wins"': 98}),     Document(page_content='Reds', metadata={' "Payroll (millions)"': 82.2, ' "Wins"': 97}),     Document(page_content='Yankees', metadata={' "Payroll (millions)"': 197.96, ' "Wins"': 95}),     Document(page_content='Giants', metadata={' "Payroll (millions)"': 117.62, ' "Wins"': 94}),     Document(page_content='Braves', metadata={' "Payroll (millions)"': 83.31, ' "Wins"': 94}),     Document(page_content='Athletics', metadata={' "Payroll (millions)"': 55.37, ' "Wins"': 94}),     Document(page_content='Rangers', metadata={' "Payroll (millions)"': 120.51, ' "Wins"': 93}),     Document(page_content='Orioles', metadata={' "Payroll (millions)"': 81.43, ' "Wins"': 93}),     Document(page_content='Rays', metadata={'
This notebook goes over how to load data from a pandas DataFrame.
This notebook goes over how to load data from a pandas DataFrame. ->: notebook goes over how to load data from a pandas DataFrame.#!pip install pandasimport pandas as pddf = pd.read_csv("example_data/mlb_teams_2012.csv")df.head()<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>Team</th>      <th>"Payroll (millions)"</th>      <th>"Wins"</th>    </tr>  </thead>  <tbody>    <tr>      <th>0</th>      <td>Nationals</td>      <td>81.34</td>      <td>98</td>    </tr>    <tr>      <th>1</th>      <td>Reds</td>      <td>82.20</td>      <td>97</td>    </tr>    <tr>      <th>2</th>      <td>Yankees</td>      <td>197.96</td>      <td>95</td>    </tr>    <tr>      <th>3</th>      <td>Giants</td>      <td>117.62</td>      <td>94</td>    </tr>    <tr>      <th>4</th>      <td>Braves</td>      <td>83.31</td>      <td>94</td>    </tr>  </tbody></table></div>from langchain.document_loaders import DataFrameLoaderloader = DataFrameLoader(df, page_content_column="Team")loader.load()    [Document(page_content='Nationals', metadata={' "Payroll (millions)"': 81.34, ' "Wins"': 98}),     Document(page_content='Reds', metadata={' "Payroll (millions)"': 82.2, ' "Wins"': 97}),     Document(page_content='Yankees', metadata={' "Payroll (millions)"': 197.96, ' "Wins"': 95}),     Document(page_content='Giants', metadata={' "Payroll (millions)"': 117.62, ' "Wins"': 94}),     Document(page_content='Braves', metadata={' "Payroll (millions)"': 83.31, ' "Wins"': 94}),     Document(page_content='Athletics', metadata={' "Payroll (millions)"': 55.37, ' "Wins"': 94}),     Document(page_content='Rangers', metadata={' "Payroll (millions)"': 120.51, ' "Wins"': 93}),     Document(page_content='Orioles', metadata={' "Payroll (millions)"': 81.43, ' "Wins"': 93}),     Document(page_content='Rays', metadata={'