plot_1Dsmooth {APCtools}  R Documentation 
gam
modelsPlots 1D smooth effects for a GAM model fitted with gam
or bam
.
plot_1Dsmooth(
model,
plot_ci = TRUE,
select,
alpha = 0.05,
ylim = NULL,
method_expTransform = "simple",
return_plotData = FALSE
)
model 

plot_ci 
If 
select 
Index of smooth term to be plotted. 
alpha 

ylim 
Optional limits of the yaxis. 
method_expTransform 
One of 
return_plotData 
If TRUE, the dataset prepared for plotting is returned. Defaults to FALSE. 
If the model was estimated with a log or logit link, the function
automatically performs an exponential transformation of the effect,
see argument method_expTransform
.
ggplot object
Alexander Bauer alexander.bauer@stat.unimuenchen.de
library(APCtools)
library(mgcv)
data(travel)
model < gam(mainTrip_distance ~ te(age, period) + residence_region +
household_size + s(household_income), data = travel)
plot_1Dsmooth(model, select = 2)