DataFrame add_prev_result(
DataFrame object, const char* subject = "subject",
const char* timepoint = "timepoint",
const char* result = "result",
const char* prev_result = "prev_result")
{
// cout << "——Rcpp::export——add_prev_result(DataFrame, const char*, const char*, const char*) subject " << subject << "; timepoint " << timepoint << "; result " << result << endl;
try {
object.push_back(prevres_intvec(object, subject, timepoint, result), prev_result);
return object;
} catch (exception& e) {
Rcerr << "Error in add_prev_result(): " << e.what() << '\n';
} catch (std::invalid_argument& iva) {
Rcerr << "Error invalid argument: " << iva.what() << '\n';
}
return DataFrame::create();
}
Transition/src/transition.cpp
Line 608 in 248269d