ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Python tool - dataframe output issue

mjbarre2
5 - Atom

Hello, 

 

I'm having issues while using PDFplumber in the python tool. My Alteryx version is 2022.3.1.486. I'm trying to replicate the output from this site

 

When trying to run my program, I get this error: "TypeError: input must be a pandas series, not a <class 'pandas.core.frame.DataFrame'>".

 

My code is (file path removed):

 

from ayx import Alteryx
import pdfplumber
import pandas as pd

file_path = "file path"
pdf = pdfplumber.open(file_path)
table = pdf.pages[0].extract_table()

df = pd.DataFrame(table[1::], columns=table[0])

Alteryx.write(df,1)

 

 

I've tried converting my desired df output to a series but then get an error stating only "only panda dataframes can be used to pass data to out going connections". Any help is appreciated. Thanks!

0 REPLIES 0
Labels
Top Solution Authors