Skip to content

Commit

Permalink
support complex values in matrixToDataFrame
Browse files Browse the repository at this point in the history
  • Loading branch information
Kirill Müller committed Oct 31, 2015
1 parent abfb411 commit ae8a4e3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/matrixToDataFrame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ List matrixToDataFrame(RObject x) {
case REALSXP:
REAL(col)[i] = REAL(x)[offset + i];
break;
case CPLXSXP:
COMPLEX(col)[i] = COMPLEX(x)[offset + i];
break;
case STRSXP:
SET_STRING_ELT(col, i, STRING_ELT(x, offset + i));
break;
Expand Down

0 comments on commit ae8a4e3

Please sign in to comment.