The init is row major (which is easier on the eyes, but
perhaps unexpected given that their default layout is
column major).

I don't think we should get into the business of documenting the way
functions in Eigen work where they are called
or we'll never stop!

Having said that, I like to lay out the arguments to
the initializer to make this clear.  In this case, that's:

    m << 1.2, 5.7, 1.0,
         2.0, 3.0, 4.0;

- Bob

On 8/26/13 5:54 PM, Daniel Lee wrote:
> In src/test/io/csv_writer_test.cpp:
>
>> @@ -52,15 +52,15 @@
>>  }
>>
>>
>> -TEST(io_csv_writer, csv_writer_matrix) {
>> +TEST(io_csv_writer, csv_writer_matrix_row_major) {
>>    std::stringstream s;
>>    stan::io::csv_writer writer(s);
>>    Eigen::Matrix<double,Eigen::Dynamic,Eigen::Dynamic> m(2,3);
>>    m << 1.2, 5.7, 1.0, 2.0, 3.0, 4.0;
>
> Can we initialize |m| explicitly? It isn't clear whether m is populated row major or column major based on this test.
>
> —
> Reply to this email directly or view it on GitHub <https://github.com/stan-dev/stan/pull/183/files#r5991398>.
>