[Rcpp-devel] how to get data from old dll which returns Microsoft variant structure
Dirk Eddelbuettel
edd at debian.org
Thu Dec 3 02:36:09 CET 2020
Shreedhar,
On 2 December 2020 at 15:48, Tase, Shreedhar wrote:
| Hi
| I have DLL which has function which returns 2D array flattened to 1-dimentional array of Microsoft variant type structure. I am able to call that function using Rcpp; I want to take that data in R.
| I want to represent that in row column format in R. I want to do that conversion in .cpp files. What are the options I have ? Any idea how to do that ? As number of rows and columns keeps on changing.
| I do not see any package which converts variant structure to R.
This, just like the post StackOverflow likely by you too [1] is a little
short on specifics.
And to be plain: no software can unpack _non-deterministic_ input optimally.
If you have such data, you have to provide some structure. One way is via
formal descriptions (package RProtoBuf uses the Protocol Buffer framework,
page RcppMsgPack uses MsgPack instead). Else if you know how to unpack it in
R well then you can do the same in C++ which may well be more efficient and
faster, but possibly a little more involved to set up. Your call.
Hope this helps, and sorry that there is no Free Lunch (TM) here.
Cheers, Dirk
[1] https://stackoverflow.com/questions/65111786/how-to-conver-variant-structure-in-r
--
https://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
More information about the Rcpp-devel
mailing list