Error: create a column from an existing array

it worked when i added commas between the strings:

using DataFrames
df = dataframe(a = rand(10))  
members = ["Belen","Lau","Javi","Joaco","Nico","Rodrigo","Vicente","Pablo","Falcao","Montse"]
julia> insertcols!(df,1, :Members =>members)
10×2 DataFrame
│ Row │ Members │ a         │        
│     │ String  │ Float64   │        
├─────┼─────────┼───────────┤
│ 1   │ Belen   │ 0.5535    │        
│ 2   │ Lau     │ 0.696888  │
│ 3   │ Javi    │ 0.285581  │        
│ 4   │ Joaco   │ 0.503806  │        
│ 5   │ Nico    │ 0.305051  │        
│ 6   │ Rodrigo │ 0.0708788 │        
│ 7   │ Vicente │ 0.268658  │
│ 8   │ Pablo   │ 0.14032   │        
│ 9   │ Falcao  │ 0.517392  │        
│ 10  │ Montse  │ 0.264026  │        

the problem seems to stem from the fact that you were trying to add a row of names as it was a column. but adding the commas solves the problem.
Other option,that works for your original input:

insertcols!(df,1, :Members =>vec(members)) #reinterprets the Array as a vector
2 Likes