pythonpandasbioservices

How can I turn this list of strings into a dataframe in pandas


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


Solution

  • 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)