In R
I can write:
l <- list(a=0, b="10");
And get the value of the element of the list named b
as follow:
x <– l$b
Is there a way to get the same result by using an Rcpp::List
object?
Of course, and there are plenty of examples. Just use
std::string x = l["b"];
where l
is the Rcpp::List
object which is assumed to have names.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With