So I've been trying to perform a discrete time survival analysis in R.
I have been using the
discSurv package to generate the augmented data matrix for the full dataset and performed an stratified train-test split.
This has just been an initial approach, but in order to test more complex procedures, I want to successfully understand what is happening each step.
After i have generated the augmented dataset (using the
dataLong function), I proceed to train a GAM model.
However, here is where i come into trouble. First of all, i don't know how to select which variables to model via a spline function, nor the parameters that should accompany them.
Moreover, which are the appropiate metrics to analyze the model with. How could I predict on the test dataset, and how could i visualize these results within R.
I have worked previously with other machine learning algorithms, but i'm very new to GAM and I can't seem to find any examples related to survival prediction analysis.