-1

Ok so essentially I extracted a large list of values from a database online using the bioservices package. What I want to do if turn this list of strings into a dataframe using pandas that I can then further format.

this is my extracted list of values from the online database that I want to turn into a pandas datafram

Inan Khan
  • 91
  • 6

1 Answers1

0

This should work for you. Just replace my list with yours.

import pandas as pd
d = ['your', 'list']
df = pd.DataFrame(columns= ['col1'],
                  data=d)
print(df)
Larry the Llama
  • 958
  • 3
  • 13
colk84
  • 92
  • 9
  • thank you so much for the answer, I feel as thought I am really close with your code but unfortunately I am getting an error that says "raise ValueError("DataFrame constructor not properly called!") ValueError: DataFrame constructor not properly called! – Inan Khan Dec 08 '21 at 12:49
  • It might have something to do with the fact that your data is string. This might help you here. https://stackoverflow.com/questions/25604115/dataframe-constructor-not-properly-called-error – colk84 Dec 09 '21 at 00:44