I was hoping to be able to fill a larger DataFrame
with the values of a smaller one using fill()
but it doesn’t work this way. I can create a new DataFrame
using vcat
but was hoping for a better method.
using DataFrames
df_test = DataFrame(a = repeat([1:2;], inner = [2]),
b = repeat([1;], inner = [4]),
c = randn(4))
df_test2 = DataFrame(zeros(16,3))
df_test3 = fill(df_test2,df_test) # does not work
df_test_4 = vcat(df_test,df_test,df_test,df_test) # does work, but more 'work' or not as elegant