visualize trend of pathogen observation rate for NPPCR data (both cases and controls)
visualize_season(data_nplcm, patho, slice = 1, slice_SS = 1)A figure with smoothed positive rate and confidence bands for cases and controls, respectively. The right margin shows marginal positive rates; all rates are only among the subset of case subjects who had non-missing responses for a measured agent (e.g., pathogen); similarly for controls.
Data set produced by clean_perch_data()
the index of pathogen
the slice of BrS data for visualization; default is 1.
the slice of SS data to add onto BrS plots; default is 1, usually representing blood culture measurements.
This function shows observed
positive rate for continuous covariates,e.g., enrollment date
in PERCH application. Smoothing is done by penalized splines implemented by
mgcv package. The penalized spline smoothing term is constructed by
mgcv::smooth.construct.ps.smooth.spec(). The window size of the moving averages currently is set
to 60 days.
Other exploratory data analysis functions:
get_top_pattern(),
plot_logORmat(),
show_individual(),
summarize_BrS(),
summarize_SS()