dataframe icon indicating copy to clipboard operation
dataframe copied to clipboard

Transposing an empty dataframe does not give the same empty dataframe.

Open mbramson opened this issue 9 years ago • 1 comments

Transposing an empty dataframe does not give a correct empty dataframe.

running this test:

  describe "transport/1" do
    test "empty Frame returns an empty Frame" do
      assert DataFrame.transpose(empty_frame()) == empty_frame()
    end
  end

gives this failed test:

  1) test transport/1 empty Frame returns an empty Frame (DataFrameTest)
     test/data_frame_test.exs:76
     Assertion with == failed
     code: DataFrame.transpose(empty_frame()) == empty_frame()
     lhs:  %DataFrame.Frame{columns: [], index: [], values: []}
     rhs:  %DataFrame.Frame{columns: [], index: [], values: [[]]}
     stacktrace:
       test/data_frame_test.exs:77: (test)

transposing an empty dataframe should give an empty dataframe exactly. This works in spirit, but the result is not correct.

mbramson avatar Oct 06 '16 23:10 mbramson

I've pushed version 0.3.1, should solve this issue.

JordiPolo avatar Oct 08 '16 12:10 JordiPolo