Skip to main content

R Code: Calculating Partial Least Squares Regression, Reduced Subset Regression Models, and Structural Equation Models associated with the analyses of threats to the eastern migratory population of monarch butterflies

Citation

Thogmartin, W. E., 2017, R code for calculating Partial Least Squares Regression, Reduced Subset Regression Models, and Structural Equation Models associated with the analyses of threats to the eastern migratory population of monarch butterflies: U.S. Geological Survey data release, https://doi.org/10.5066/F7SX6BZ1.

Summary

The code includes: MonarchThreatsCode.R, which provides all code used in the analysis. Required data includes: FullThreatsData.csv and component_loadings.csv While the code demonstrates how to interpolate the missing data, the FullThreatsData.csv has all missing values filled in. Similarly, the partial least squares demonstrates how the PLS was conducted, but the component_loadings.csv file contains the actual loadings presented in the paper. Outputs include: Partial least squares model results, plots of the partial least squares loadings, exploratory regression analysis, plotting of the parameter estimates from the best model, confounding analysis, structural equation modeling, and other plotting functions depicting results of the [...]

Contacts

Point of Contact :
Wayne E Thogmartin

Attached Files

Click on title to download individual files attached to this item.

LICENSE.note.txt 2.65 KB text/plain
MonarchThreatsCode.R 29.53 KB text/x-rsrc
ReadMe.txt 1.04 KB text/plain

Communities

  • Upper Midwest Environmental Sciences Center (UMESC)

Provenance

Data source
Input directly

Item Actions

View Item as ...

Save Item as ...

View Item...