SAS Code: Fitting linear models with multivariate random effects and heterogeneous measurement-level residual variances
Citation
Brian Gray, 2018, SAS code for fitting linear models with multivariate random effects and heterogeneous measurement-level residual variances, U.S. Geological Survey software release, https://doi.org/10.5066/F76972TT.
Summary
This code may be used to fit linear models with multivariate random effects and heterogeneous measurement-level residual variances. The code as written may be used to estimate associations between water temperature ('temp') and continuous year ('yearctr'), study reach (or field station; 'fs'), log-transformed mean July water discharge (in 1000 cms units; 'logmeanJulycms1000'), number of days from a central sampling date (for a given year, days from a standard month and day; 'jdatectr'), time of sampling (in fractions of hours from noon on the given date; 'timectrhr') and interactions thereof. Water, discharge and air data may be obtained from https://www.umesc.usgs.gov/data_library/water_quality/water1_query.shtml, http://waterdata.usgs.gov [...]
Summary
This code may be used to fit linear models with multivariate random effects and heterogeneous measurement-level residual variances. The code as written may be used to estimate associations between water temperature ('temp') and continuous year ('yearctr'), study reach (or field station; 'fs'), log-transformed mean July water discharge (in 1000 cms units; 'logmeanJulycms1000'), number of days from a central sampling date (for a given year, days from a standard month and day; 'jdatectr'), time of sampling (in fractions of hours from noon on the given date; 'timectrhr') and interactions thereof. Water, discharge and air data may be obtained from https://www.umesc.usgs.gov/data_library/water_quality/water1_query.shtml, http://waterdata.usgs.gov and http://mrcc.isws.illinois.edu/, respectively.
files
LMM.sas is the SAS code that may be used to fit the models mentioned above