maineffect {APCI} | R Documentation |

## Estimate age effect and period effect

### Description

Estimate age and period effect from APCI model

### Usage

```
maineffect(A, P, C, model = temp6, data, gee = FALSE, ...)
```

### Arguments

`A` , `P` , `C` |
The numbers of age groups, period groups, and cohort groups separately. |

`model` |
A generalized linear regression model generated from the internal function temp_model |

`data` |
A data frame containing the outcome variable, age group indicator, period group indicator, and covariates to be used in the model. If the variable(s) are not found in data, there will be an error message reminding the users to check the input data again. |

`gee` |
Logical, indicating if the data is cross-sectional data or
longitudinal/panel data. If |

`...` |
Additional arguments to be passed to the function. |

### Value

A list containing:

`intercept` |
The overall intercept. |

`age_effect` |
The estimated age main effect. |

`period_effect` |
The estimated period main effect. |

*APCI*version 1.0.7 Index]