mrgsolve
Public Member Functions | Public Attributes | List of all members
dataobject Class Reference

#include <dataobject.h>

Public Member Functions

 dataobject (Rcpp::NumericMatrix _data, Rcpp::CharacterVector _parnames)
 constructor More...
 
 dataobject (Rcpp::NumericMatrix _data, Rcpp::CharacterVector _parnames, Rcpp::CharacterVector _initnames)
 constructor More...
 
 ~dataobject ()
 
unsigned int nrow () const
 
unsigned int ncol () const
 
unsigned int nid () const
 
unsigned int idcol () const
 
int start (int i) const
 
int end (int i) const
 
void map_uid ()
 
double get_uid (int i) const
 
uidtype return_uid ()
 
void copy_parameters (int this_row, odeproblem *prob)
 
void copy_next_parameters (int id_n, bool from_data, int this_row, odeproblem *prob)
 
void next_id (int id_n)
 
void copy_inits (int this_row, odeproblem *prob)
 
void reload_parameters (const Rcpp::NumericVector &param, odeproblem *prob)
 
void idata_row ()
 
unsigned int get_idata_row (const double ID)
 
void locate_tran ()
 
void get_records (recstack &a, int NID, int neq, unsigned int &obscount, unsigned int &evcount, bool obsonly, bool debug)
 
void get_records_pred (recstack &a, int NID, int neq, unsigned int &obscount, unsigned int &evcount, bool obsonly, bool debug)
 
void check_idcol (dataobject &data)
 
double get_value (const int row, const int col) const
 
double get_id_value (const int row) const
 
Rcpp::IntegerVector get_col_n (const Rcpp::CharacterVector &what)
 
void carry_out (const recstack &a, Rcpp::NumericMatrix &ans, dataobject &idat, const Rcpp::IntegerVector &data_carry, const unsigned int data_carry_start, const Rcpp::IntegerVector &idata_carry, const unsigned int idata_carry_start)
 

Public Attributes

Rcpp::NumericMatrix Data
 
std::vector< unsigned int > col
 
Rcpp::CharacterVector Data_names
 
std::deque< double > Uid
 unique IDs in the data set More...
 
std::deque< int > Startrow
 start row for each ID More...
 
std::deque< int > Endrow
 data set end row for each ID More...
 
int Idcol
 which column holds ID More...
 
std::map< double, int > idmap
 map to get More...
 
std::vector< int > par_from
 index for parameters in data set More...
 
std::vector< int > par_to
 index for parameters in param list More...
 
Rcpp::CharacterVector parnames
 names of model parameters More...
 
std::vector< int > cmt_from
 index for compartments in data set More...
 
std::vector< int > cmt_to
 index for compartments in init list More...
 
Rcpp::CharacterVector cmtnames
 names of model compartments More...
 
bool any_copy
 are there any parameter columns for copy / update? More...
 
bool done_copying
 have we reached the last data record for this ID? More...
 
int next_copy_row
 tracking current actual data row More...
 
int last_copy_row
 tracking previous actual data row More...
 

Constructor & Destructor Documentation

◆ dataobject() [1/2]

dataobject::dataobject ( Rcpp::NumericMatrix  _data,
Rcpp::CharacterVector  _parnames 
)

constructor

◆ dataobject() [2/2]

dataobject::dataobject ( Rcpp::NumericMatrix  _data,
Rcpp::CharacterVector  _parnames,
Rcpp::CharacterVector  _initnames 
)

constructor

◆ ~dataobject()

dataobject::~dataobject ( )

Member Function Documentation

◆ carry_out()

void dataobject::carry_out ( const recstack a,
Rcpp::NumericMatrix &  ans,
dataobject idat,
const Rcpp::IntegerVector &  data_carry,
const unsigned int  data_carry_start,
const Rcpp::IntegerVector &  idata_carry,
const unsigned int  idata_carry_start 
)

◆ check_idcol()

void dataobject::check_idcol ( dataobject data)

◆ copy_inits()

void dataobject::copy_inits ( int  this_row,
odeproblem prob 
)

◆ copy_next_parameters()

void dataobject::copy_next_parameters ( int  id_n,
bool  from_data,
int  this_row,
odeproblem prob 
)

◆ copy_parameters()

void dataobject::copy_parameters ( int  this_row,
odeproblem prob 
)

◆ end()

int dataobject::end ( int  i) const
inline

◆ get_col_n()

Rcpp::IntegerVector dataobject::get_col_n ( const Rcpp::CharacterVector &  what)

◆ get_id_value()

double dataobject::get_id_value ( const int  row) const
inline

◆ get_idata_row()

unsigned int dataobject::get_idata_row ( const double  ID)

◆ get_records()

void dataobject::get_records ( recstack a,
int  NID,
int  neq,
unsigned int &  obscount,
unsigned int &  evcount,
bool  obsonly,
bool  debug 
)

◆ get_records_pred()

void dataobject::get_records_pred ( recstack a,
int  NID,
int  neq,
unsigned int &  obscount,
unsigned int &  evcount,
bool  obsonly,
bool  debug 
)

◆ get_uid()

double dataobject::get_uid ( int  i) const
inline

◆ get_value()

double dataobject::get_value ( const int  row,
const int  col 
) const
inline

◆ idata_row()

void dataobject::idata_row ( )

◆ idcol()

unsigned int dataobject::idcol ( ) const
inline

◆ locate_tran()

void dataobject::locate_tran ( )

◆ map_uid()

void dataobject::map_uid ( )

◆ ncol()

unsigned int dataobject::ncol ( ) const
inline

◆ next_id()

void dataobject::next_id ( int  id_n)

◆ nid()

unsigned int dataobject::nid ( ) const
inline

◆ nrow()

unsigned int dataobject::nrow ( ) const
inline

◆ reload_parameters()

void dataobject::reload_parameters ( const Rcpp::NumericVector &  param,
odeproblem prob 
)

◆ return_uid()

uidtype dataobject::return_uid ( )
inline

◆ start()

int dataobject::start ( int  i) const
inline

Member Data Documentation

◆ any_copy

bool dataobject::any_copy

are there any parameter columns for copy / update?

◆ cmt_from

std::vector<int> dataobject::cmt_from

index for compartments in data set

◆ cmt_to

std::vector<int> dataobject::cmt_to

index for compartments in init list

◆ cmtnames

Rcpp::CharacterVector dataobject::cmtnames

names of model compartments

◆ col

std::vector<unsigned int> dataobject::col

◆ Data

Rcpp::NumericMatrix dataobject::Data

◆ Data_names

Rcpp::CharacterVector dataobject::Data_names

◆ done_copying

bool dataobject::done_copying

have we reached the last data record for this ID?

◆ Endrow

std::deque<int> dataobject::Endrow

data set end row for each ID

◆ Idcol

int dataobject::Idcol

which column holds ID

◆ idmap

std::map<double,int> dataobject::idmap

map to get

◆ last_copy_row

int dataobject::last_copy_row

tracking previous actual data row

◆ next_copy_row

int dataobject::next_copy_row

tracking current actual data row

◆ par_from

std::vector<int> dataobject::par_from

index for parameters in data set

◆ par_to

std::vector<int> dataobject::par_to

index for parameters in param list

◆ parnames

Rcpp::CharacterVector dataobject::parnames

names of model parameters

◆ Startrow

std::deque<int> dataobject::Startrow

start row for each ID

◆ Uid

std::deque<double> dataobject::Uid

unique IDs in the data set


The documentation for this class was generated from the following files: