如何从熊猫数据框增量打印?

时间:2019-08-02 14:35:26

标签: python loops for-loop indexing while-loop

编程的新手-尝试让我的代码从电子表格中获取订单号列表,然后在外部数据库中搜索它们。现在,我只是想让电子表格的“ ONEA”列逐步打印。

我认为我还有很长的路要走,但是下面的代码至少应该说明我要完成的工作。


df = pd.read_excel('Test1.xlsx', sheet_name='Sheet1')

listONEA = df['ONEA']

# and what I'm trying to do is:

for i in range(10):
    print(listONEA[i])
    i =+ 1

1 个答案:

答案 0 :(得分:0)

熊猫系列(您的public class JavaFile2 extends frameworkClass{ @Test(priority = 0, groups = { "webdriver", "UI","helloTest1"}) public void test1(){} @Test(priority = 1, groups = { "webdriver", "UI","helloTest1"}) public void test2(){} @Test(priority = 2, groups = { "webdriver", "UI","helloTest1"}) public void test3(){} @Test(priority = 3, groups = { "webdriver", "UI","helloTest1"}) public void test4(){} @Test(priority = 4, groups = { "webdriver", "UI","helloTest1"}) public void test5(){} } )具有方法df['ONEA']

.tolist

Pandas DataFrame column to list