y: a vector of possible y values in order (numeric, character, factor)
times: vector of measurement times
initial: initial value of y (baseline state; numeric, character, factr)
absorb: vector of absorbing states, a subset of y. The default is no absorbing states. (numeric, character, factor)
intercepts: vector of intercepts in the proportional odds model, with length one less than the length of y
g: a user-specified function of three or more arguments which in order are yprev - the value of y at the previous time, the current time t, the gap between the previous time and the current time, an optional (usually named) covariate vector X, and optional arguments such as a regression coefficient value to simulate from. The function needs to allow yprev to be a vector and yprev must not include any absorbing states. The g function returns the linear predictor for the proportional odds model aside from intercepts. The returned value must be a matrix with row names taken from yprev. If the model is a proportional odds model, the returned value must be one column. If it is a partial proportional odds model, the value must have one column for each distinct value of the response variable Y after the first one, with the levels of Y used as optional column names. So columns correspond to intercepts. The different columns are used for y-specific contributions to the linear predictor (aside from intercepts) for a partial or constrained partial proportional odds model. Parameters for partial proportional odds effects may be included in the ... arguments.
...: additional arguments to pass to g such as covariate settings
Returns
matrix with rows corresponding to times and columns corresponding to states, with values equal to exact state occupancy probabilities